home *** CD-ROM | disk | FTP | other *** search
/ SGI Freeware 2002 November / SGI Freeware 2002 November - Disc 2.iso / dist / fw_gnuplot.idb / usr / freeware / doc / gnuplot / gnuplot.ms.z / gnuplot.ms
Text File  |  2002-01-08  |  334KB  |  11,308 lines

  1. .if n \{.nr LL +8m
  2. .na \}
  3. .nr PO +0.3i
  4. .so titlepag.ms
  5. .pn 1
  6. .bp
  7. .ta 1.5i 3.0i 4.5i 6.0i 7.5i
  8. \&
  9. .sp 3
  10. .PP
  11. .sp 3
  12. .NH 1
  13. Gnuplot
  14. .sp 1
  15. .LP
  16. .XS
  17. Gnuplot
  18. .XE
  19. .sp 2
  20. .NH 1
  21. Copyright
  22. .sp 1
  23. .LP
  24. .XS
  25. Copyright
  26. .XE
  27. .br
  28.       Copyright (C) 1986 - 1993, 1998   Thomas Williams, Colin Kelley
  29. .br
  30.  
  31. Permission to use, copy, and distribute this software and its
  32. documentation for any purpose with or without fee is hereby granted,
  33. provided that the above copyright notice appear in all copies and
  34. that both that copyright notice and this permission notice appear
  35. in supporting documentation.
  36.  
  37. Permission to modify the software is granted, but not the right to
  38. distribute the complete modified source code.  Modifications are to
  39. be distributed as patches to the released version.  Permission to
  40. distribute binaries produced by compiling modified sources is granted,
  41. provided you
  42. .br
  43.   1. distribute the corresponding source modifications from the
  44. .br
  45. .br
  46.    released version in the form of a patch file along with the binaries,
  47. .br
  48. .br
  49.   2. add special version identification to distinguish your version
  50. .br
  51. .br
  52.    in addition to the base release version number,
  53. .br
  54. .br
  55.   3. provide your name and address as the primary contact for the
  56. .br
  57. .br
  58.    support of your modified version, and
  59. .br
  60. .br
  61.   4. retain our contact information in regard to use of the base
  62. .br
  63. .br
  64.    software.
  65. .br
  66. Permission to distribute the released version of the source code along
  67. with corresponding source modifications in the form of a patch file is
  68. granted with same provisions 2 through 4 for binary distributions.
  69.  
  70. This software is provided "as is" without express or implied warranty
  71. to the extent permitted by applicable law.
  72.  
  73.  
  74. .br
  75.       AUTHORS
  76. .br
  77.  
  78. .br
  79.       Original Software:
  80. .br
  81. .br
  82.          Thomas Williams,  Colin Kelley.
  83. .br
  84.  
  85. .br
  86.       Gnuplot 2.0 additions:
  87. .br
  88. .br
  89.          Russell Lang, Dave Kotz, John Campbell.
  90. .br
  91.  
  92. .br
  93.       Gnuplot 3.0 additions:
  94. .br
  95. .br
  96.          Gershon Elber and many others.
  97. .br
  98. .sp 2
  99. .NH 1
  100. Introduction
  101. .sp 1
  102. .LP
  103. .XS
  104. Introduction
  105. .XE
  106. \fBgnuplot\fR is a command-driven interactive function and data plotting program.
  107. It is case sensitive (commands and function names written in lowercase are
  108. not the same as those written in CAPS).  All command names may be abbreviated
  109. as long as the abbreviation is not ambiguous.  Any number of commands may
  110. appear on a line (with the exception that \fBload\fR or \fBcall\fR must be the final
  111. command), separated by semicolons (;).  Strings are indicated with quotes.
  112. They may be either single or double quotation marks, e.g.,
  113.  
  114. .br
  115.       load "filename"
  116. .br
  117. .br
  118.       cd 'dir'
  119. .br
  120.  
  121. although there are some subtle differences (see \fBsyntax\fR for more details).
  122.  
  123. Any command-line arguments are assumed to be names of files containing
  124. \fBgnuplot\fR commands, with the exception of standard X11 arguments, which are
  125. processed first.  Each file is loaded with the \fBload\fR command, in the order
  126. specified.  \fBgnuplot\fR exits after the last file is processed.  When no load
  127. files are named, \fBgnuplot\fR enters into an interactive mode.  The special
  128. filename "-" is used to denote standard input.  See "help batch/interactive"
  129. for more details.
  130.  
  131. Many \fBgnuplot\fR commands have multiple options.  These options must appear in
  132. the proper order, although unwanted ones may be omitted in most cases.  Thus
  133. if the entire command is "command a b c", then "command a c" will probably
  134. work, but "command c a" will fail.
  135.  
  136. Commands may extend over several input lines by ending each line but the last
  137. with a backslash (\\).  The backslash must be the _last_ character on each
  138. line.  The effect is as if the backslash and newline were not there.  That
  139. is, no white space is implied, nor is a comment terminated.  Therefore,
  140. commenting out a continued line comments out the entire command (see
  141. \fBcomment\fR).  But note that if an error occurs somewhere on a multi-line
  142. command, the parser may not be able to locate precisely where the error is
  143. and in that case will not necessarily point to the correct line.
  144.  
  145. In this document, curly braces ({}) denote optional arguments and a vertical
  146. bar (|) separates mutually exclusive choices.  \fBgnuplot\fR keywords or \fBhelp\fR
  147. topics are indicated by backquotes or \fBboldface\fR (where available).  Angle
  148. brackets (<>) are used to mark replaceable tokens.  In many cases, a default
  149. value of the token will be taken for optional arguments if the token is
  150. omitted, but these cases are not always denoted with braces around the angle
  151. brackets.
  152.  
  153. For on-line help on any topic, type \fBhelp\fR followed by the name of the topic
  154. or just \fBhelp\fR or \fB?\fR to get a menu of available topics.
  155.  
  156. The new \fBgnuplot\fR user should begin by reading about \fBplotting\fR (if on-line,
  157. type \fBhelp plotting\fR).
  158. .sp 2
  159. .NH 1
  160. Seeking-assistance
  161. .sp 1
  162. .LP
  163. .XS
  164. Seeking-assistance
  165. .XE
  166. There is a mailing list for \fBgnuplot\fR users.  Note, however, that the
  167. newsgroup
  168. .br
  169.       comp.graphics.apps.gnuplot
  170. .br
  171. is identical to the mailing list (they both carry the same set of messages).
  172. We prefer that you read the messages through the newsgroup rather than
  173. subscribing to the mailing list.  Administrative requests should be sent to
  174. .br
  175.       majordomo@dartmouth.edu
  176. .br
  177. Send a message with the body (not the subject) consisting of the single word
  178. "help" (without the quotes) for more details.
  179.  
  180. The address for mailing to list members is:
  181. .br
  182.       info-gnuplot@dartmouth.edu
  183. .br
  184.  
  185. Bug reports and code contributions should be mailed to:
  186. .br
  187.       bug-gnuplot@dartmouth.edu
  188. .br
  189.  
  190. The list of those interested in beta-test versions is:
  191. .br
  192.       info-gnuplot-beta@dartmouth.edu
  193. .br
  194.  
  195. There is also a World Wide Web page with up-to-date information, including
  196. known bugs:
  197. .br
  198.       http://www.cs.dartmouth.edu/gnuplot_info.html
  199. .br
  200.  
  201. Before seeking help, please check the
  202. FAQ (Frequently Asked Questions) list.
  203. If you do not have a copy of the FAQ, you may request a copy by email from
  204. the Majordomo address above, ftp a copy from
  205. .br
  206.       ftp://ftp.ucc.ie/pub/gnuplot/faq,
  207. .br
  208. .br
  209.       ftp://ftp.gnuplot.vt.edu/pub/gnuplot/faq,
  210. .br
  211. or see the WWW \fBgnuplot\fR page.
  212.  
  213. When posting a question, please include full details of the version of
  214. \fBgnuplot\fR, the machine, and operating system you are using.  A _small_ script
  215. demonstrating the problem may be useful.  Function plots are preferable to
  216. datafile plots.  If email-ing to info-gnuplot, please state whether or not
  217. you are subscribed to the list, so that users who use news will know to email
  218. a reply to you.  There is a form for such postings on the WWW site.
  219. .sp 2
  220. .NH 1
  221. What's New in version 3.7
  222. .sp 1
  223. .LP
  224. .XS
  225. What's New in version 3.7
  226. .XE
  227. Gnuplot version 3.7 contains many new features.  This section gives a partial
  228. list and links to the new items in no particular order.
  229.  
  230. 1. \fBfit f(x) \&'file\&' via\fR uses the Marquardt-Levenberg method to fit data.
  231. (This is only slightly different from the \fBgnufit\fR patch available for 3.5.)
  232.  
  233. 2. Greatly expanded \fBusing\fR command.  See \fBplot using\fR.
  234.  
  235. 3. \fBset timefmt\fR allows for the use of dates as input and output for time
  236. series plots.  See \fBTime/Date data\fR and
  237. timedat.dem.
  238.  
  239. 4. Multiline labels and font selection in some drivers.
  240.  
  241. 5. Minor (unlabeled) tics.  See \fBset mxtics\fR.
  242.  
  243. 6. \fBkey\fR options for moving the key box in the page (and even outside of the
  244. plot), putting a title on it and a box around it, and more.  See \fBset key\fR.
  245.  
  246. 7. Multiplots on a single logical page with \fBset multiplot\fR.
  247.  
  248. 8. Enhanced \fBpostscript\fR driver with super/subscripts and font changes.
  249. (This was a separate driver (\fBenhpost\fR) that was available as a patch for
  250. 3.5.)
  251.  
  252. 9. Second axes:  use the top and right axes independently of the bottom and
  253. left, both for plotting and labels.  See \fBplot\fR.
  254.  
  255. 10. Special datafile names \fB\&'-\&'\fR and \fB""\fR.  See \fBplot special-filenames\fR.
  256.  
  257. 11. Additional coordinate systems for labels and arrows.  See \fBcoordinates\fR.
  258.  
  259. 12. \fBset size\fR can try to plot with a specified aspect ratio.
  260.  
  261. 13. \fBset missing\fR now treats missing data correctly.
  262.  
  263. 14. The \fBcall\fR command: \fBload\fR with arguments.
  264.  
  265. 15. More flexible \fBrange\fR commands with \fBreverse\fR and \fBwriteback\fR keywords.
  266.  
  267. 16. \fBset encoding\fR for multi-lingual encoding.
  268.  
  269. 17. New \fBx11\fR driver with persistent and multiple windows.
  270.  
  271. 18. New plotting styles: \fBxerrorbars\fR, \fBhisteps\fR, \fBfinancebars\fR and more.
  272. See \fBset style\fR.
  273.  
  274. 19. New tic label formats, including \fB"%l %L"\fR which uses the mantissa and
  275. exponents to a given base for labels.  See \fBset format\fR.
  276.  
  277. 20. New drivers, including \fBcgm\fR for inclusion into MS-Office applications
  278. and \fBgif\fR for serving plots to the WEB.
  279.  
  280. 21. Smoothing and spline-fitting options for \fBplot\fR.  See \fBplot smooth\fR.
  281.  
  282. 22. \fBset margin\fR and \fBset origin\fR give much better control over where a
  283. graph appears on the page.
  284.  
  285. 23. \fBset border\fR now controls each border individually.
  286.  
  287. 24. The new commands \fBif\fR and \fBreread\fR allow command loops.
  288.  
  289. 25. Point styles and sizes, line types and widths can be specified on the
  290. \fBplot\fR command.  Line types and widths can also be specified for grids,
  291. borders, tics and arrows.  See \fBplot with\fR.  Furthermore these types may be
  292. combined and stored for further use.  See \fBset linestyle\fR.
  293.  
  294. 26. Text (labels, tic labels, and the time stamp) can be written vertically
  295. by those terminals capable of doing so.
  296. .sp 2
  297. .NH 1
  298. Batch/Interactive Operation
  299. .sp 1
  300. .LP
  301. .XS
  302. Batch/Interactive Operation
  303. .XE
  304. \fBgnuplot\fR may be executed in either batch or interactive modes, and the two
  305. may even be mixed together on many systems.
  306.  
  307. Any command-line arguments are assumed to be names of files containing
  308. \fBgnuplot\fR commands (with the exception of standard X11 arguments, which are
  309. processed first).  Each file is loaded with the \fBload\fR command, in the order
  310. specified.  \fBgnuplot\fR exits after the last file is processed.  When no load
  311. files are named, \fBgnuplot\fR enters into an interactive mode.  The special
  312. filename "-" is used to denote standard input.
  313.  
  314. Both the \fBexit\fR and \fBquit\fR commands terminate the current command file and
  315. \fBload\fR the next one, until all have been processed.
  316.  
  317. Examples:
  318.  
  319. To launch an interactive session:
  320. .br
  321.       gnuplot
  322. .br
  323.  
  324. To launch a batch session using two command files "input1" and "input2":
  325. .br
  326.       gnuplot input1 input2
  327. .br
  328.  
  329. To launch an interactive session after an initialization file "header" and
  330. followed by another command file "trailer":
  331. .br
  332.       gnuplot header - trailer
  333. .br
  334. .sp 2
  335. .NH 1
  336. Command-line-editing
  337. .sp 1
  338. .LP
  339. .XS
  340. Command-line-editing
  341. .XE
  342. Command-line editing is supported by the Unix, Atari, VMS, MS-DOS and OS/2
  343. versions of \fBgnuplot\fR.  Also, a history mechanism allows previous commands to
  344. be edited and re-executed.  After the command line has been edited, a newline
  345. or carriage return will enter the entire line without regard to where the
  346. cursor is positioned.
  347.  
  348. (The readline function in \fBgnuplot\fR is not the same as the readline used in
  349. GNU Bash and GNU Emacs.  If the GNU version is desired, it may be selected
  350. instead of the \fBgnuplot\fR version at compile time.)
  351.  
  352.  
  353. The editing commands are as follows:
  354.  
  355.  
  356. .EQ
  357. delim $$
  358. .EN
  359. .KS
  360. .TS
  361. center box tab (@) ;
  362. c l .
  363. Character@Function
  364. _
  365. @Line Editing
  366. ^B@move back a single character.
  367. ^F@move forward a single character.
  368. ^A@move to the beginning of the line.
  369. ^E@move to the end of the line.
  370. ^H, DEL@delete the previous character.
  371. ^D@delete the current character.
  372. ^K@delete from current position to the end of line.
  373. ^L, ^R@redraw line in case it gets trashed.
  374. ^U@delete the entire line.
  375. ^W@delete from the current word to the end of line.
  376. _
  377. @History
  378. ^P@move back through history.
  379. ^N@move forward through history.
  380. .TE
  381. .KE
  382. .EQ
  383. delim off
  384. .EN
  385.  
  386.  
  387. On the IBM PC, the use of a TSR program such as DOSEDIT or CED may be desired
  388. for line editing.  The default makefile assumes that this is the case;  by
  389. default \fBgnuplot\fR will be compiled with no line-editing capability.  If you
  390. want to use \fBgnuplot\fR\&'s line editing, set READLINE in the makefile and add
  391. readline.obj to the link file.  The following arrow keys may be used on the
  392. IBM PC and Atari versions if readline is used:
  393.  
  394.  
  395. .EQ
  396. delim $$
  397. .EN
  398. .KS
  399. .TS
  400. center box tab (@) ;
  401. c l .
  402. Arrow key@Function
  403. _
  404. Left Arrow@same as ^B.
  405. Right Arrow@same as ^F.
  406. Ctrl Left Arrow@same as ^A.
  407. Ctrl Right Arrow@same as ^E.
  408. Up Arrow@same as ^P.
  409. Down Arrow@same as ^N.
  410. _
  411. .TE
  412. .KE
  413. .EQ
  414. delim off
  415. .EN
  416.  
  417.  
  418. The Atari version of readline defines some additional key aliases:
  419.  
  420.  
  421. .EQ
  422. delim $$
  423. .EN
  424. .KS
  425. .TS
  426. center box tab (@) ;
  427. c l .
  428. Arrow key@Function
  429. _
  430. Undo@same as ^L.
  431. Home@same as ^A.
  432. Ctrl Home@same as ^E.
  433. Esc@same as ^U.
  434. Help@help plus return.
  435. Ctrl Help@help .
  436. _
  437. .TE
  438. .KE
  439. .EQ
  440. delim off
  441. .EN
  442.  
  443. .sp 2
  444. .NH 1
  445. Comments
  446. .sp 1
  447. .LP
  448. .XS
  449. Comments
  450. .XE
  451. Comments are supported as follows: a \fB#\fR may appear in most places in a line
  452. and \fBgnuplot\fR will ignore the rest of the line.  It will not have this effect
  453. inside quotes, inside numbers (including complex numbers), inside command
  454. substitutions, etc.  In short, it works anywhere it makes sense to work.
  455. .sp 2
  456. .NH 1
  457. Coordinates
  458. .sp 1
  459. .LP
  460. .XS
  461. Coordinates
  462. .XE
  463. The commands \fBset arrow\fR, \fBset key\fR, and \fBset label\fR allow you to draw
  464. something at an arbitrary position on the graph.  This position is specified
  465. by the syntax:
  466.  
  467. .br
  468.       {<system>} <x>, {<system>} <y> {,{<system>} <z>}
  469. .br
  470.  
  471. Each <system> can either be \fBfirst\fR, \fBsecond\fR, \fBgraph\fR or \fBscreen\fR.
  472.  
  473. \fBfirst\fR places the x, y, or z coordinate in the system defined by the left
  474. and bottom axes; \fBsecond\fR places it in the system defined by the second axes
  475. (top and right); \fBgraph\fR specifies the area within the axes---0,0 is bottom
  476. left and 1,1 is top right (for splot, 0,0,0 is bottom left of plotting area;
  477. use negative z to get to the base---see \fBset ticslevel\fR); and \fBscreen\fR
  478. specifies the screen area (the entire area---not just the portion selected by
  479. \fBset size\fR), with 0,0 at bottom left and 1,1 at top right.
  480.  
  481. If the coordinate system for x is not specified, \fBfirst\fR is used.  If the
  482. system for y is not specified, the one used for x is adopted.
  483.  
  484. If one (or more) axis is timeseries, the appropriate coordinate should
  485. be given as a quoted time string according to the \fBtimefmt\fR format string.
  486. See \fBset xdata\fR and \fBset timefmt\fR.  \fBgnuplot\fR will also accept an integer
  487. expression, which will be interpreted as seconds from 1 January 2000.
  488. .sp 2
  489. .NH 1
  490. Environment
  491. .sp 1
  492. .LP
  493. .XS
  494. Environment
  495. .XE
  496. A number of shell environment variables are understood by \fBgnuplot\fR.  None of
  497. these are required, but may be useful.
  498.  
  499. If GNUTERM is defined, it is used as the name of the terminal type to be
  500. used.  This overrides any terminal type sensed by \fBgnuplot\fR on start-up, but
  501. is itself overridden by the .gnuplot (or equivalent) start-up file (see
  502. \fBstart-up\fR) and, of course, by later explicit changes.
  503.  
  504. On Unix, AmigaOS, AtariTOS, MS-DOS and OS/2, GNUHELP may be defined to be the
  505. pathname of the HELP file (gnuplot.gih).
  506.  
  507. On VMS, the logical name GNUPLOT$HELP should be defined as the name of the
  508. help library for \fBgnuplot\fR.  The \fBgnuplot\fR help can be put inside any system
  509. help library, allowing access to help from both within and outside \fBgnuplot\fR
  510. if desired.
  511.  
  512. On Unix, HOME is used as the name of a directory to search for a .gnuplot
  513. file if none is found in the current directory.  On AmigaOS, AtariTOS,
  514. MS-DOS and OS/2, gnuplot is used.  On VMS, SYS$LOGIN: is used. See \fBhelp
  515. start-up\fR.
  516.  
  517. On Unix, PAGER is used as an output filter for help messages.
  518.  
  519. On Unix, AtariTOS and AmigaOS, SHELL is used for the \fBshell\fR command.  On
  520. MS-DOS and OS/2, COMSPEC is used for the \fBshell\fR command.
  521.  
  522. On MS-DOS, if the BGI or Watcom interface is used, PCTRM is used to tell
  523. the maximum resolution supported by your monitor by setting it to
  524. S<max. horizontal resolution>. E.g. if your monitor\&'s maximum resolution is
  525. 800x600, then use:
  526. .br
  527.       set PCTRM=S800
  528. .br
  529. If PCTRM is not set, standard VGA is used.
  530.  
  531. FIT_SCRIPT may be used to specify a \fBgnuplot\fR command to be executed when a
  532. fit is interrupted---see \fBfit\fR.  FIT_LOG specifies the filename of the
  533. logfile maintained by fit.
  534. .sp 2
  535. .NH 1
  536. Expressions
  537. .sp 1
  538. .LP
  539. .XS
  540. Expressions
  541. .XE
  542. In general, any mathematical expression accepted by C, FORTRAN, Pascal, or
  543. BASIC is valid.  The precedence of these operators is determined by the
  544. specifications of the C programming language.  White space (spaces and tabs)
  545. is ignored inside expressions.
  546.  
  547. Complex constants are expressed as {<real>,<imag>}, where <real> and <imag>
  548. must be numerical constants.  For example, {3,2} represents 3 + 2i; {0,1}
  549. represents \&'i\&' itself.  The curly braces are explicitly required here.
  550.  
  551. Note that gnuplot uses both "real" and "integer" arithmetic, like FORTRAN and
  552. C.  Integers are entered as "1", "-10", etc; reals as "1.0", "-10.0", "1e1",
  553. 3.5e-1, etc.  The most important difference between the two forms is in
  554. division: division of integers truncates: 5/2 = 2; division of reals does
  555. not: 5.0/2.0 = 2.5.  In mixed expressions, integers are "promoted" to reals
  556. before evaluation: 5/2e0 = 2.5.  The result of division of a negative integer
  557. by a positive one may vary among compilers.  Try a test like "print -5/2" to
  558. determine if your system chooses -2 or -3 as the answer.
  559.  
  560. The integer expression "1/0" may be used to generate an "undefined" flag,
  561. which causes a point to ignored; the \fBternary\fR operator gives an example.
  562.  
  563. The real and imaginary parts of complex expressions are always real, whatever
  564. the form in which they are entered: in {3,2} the "3" and "2" are reals, not
  565. integers.
  566. .sp 2
  567. .RS
  568. .IP
  569. .NH 2
  570. Functions
  571. .sp 1
  572. .LP
  573. .XS
  574. Functions
  575. .XE
  576. The functions in \fBgnuplot\fR are the same as the corresponding functions in
  577. the Unix math library, except that all functions accept integer, real, and
  578. complex arguments, unless otherwise noted.
  579.  
  580. For those functions that accept or return angles that may be given in either
  581. degrees or radians (sin(x), cos(x), tan(x), asin(x), acos(x), atan(x),
  582. atan2(x) and arg(z)), the unit may be selected by \fBset angles\fR, which
  583. defaults to radians.
  584.  
  585.  
  586. .EQ
  587. delim $$
  588. .EN
  589. .KS
  590. .TS
  591. center box tab (@) ;
  592. c c l .
  593. Function@Arguments@Returns
  594. _
  595. abs(x)@any@absolute value of $x$, $|x|$; same type
  596. abs(x)@complex@length of $x$, $sqrt{roman real (x) sup 2 + roman imag (x) sup 2}$
  597. acos(x)@any@$cos sup -1 x$ (inverse cosine)
  598. acosh(x)@any@$cosh sup -1 x$ (inverse hyperbolic cosine) in radians
  599. arg(x)@complex@the phase of $x$
  600. asin(x)@any@$sin sup -1 x$ (inverse sin)
  601. asinh(x)@any@$sinh sup -1 x$ (inverse hyperbolic sin) in radians
  602. atan(x)@any@$tan sup -1 x$ (inverse tangent)
  603. atan2(y,x)@int or real@$tan sup -1 (y/x)$ (inverse tangent)
  604. atanh(x)@any@$tanh sup -1 x$ (inverse hyperbolic tangent) in radians
  605. besj0(x)@int or real@$j sub 0$ Bessel function of $x$, in radians
  606. besj1(x)@int or real@$j sub 1$ Bessel function of $x$, in radians
  607. besy0(x)@int or real@$y sub 0$ Bessel function of $x$, in radians
  608. besy1(x)@int or real@$y sub 1$ Bessel function of $x$, in radians
  609. ceil(x)@any@$left ceiling x right ceiling$, smallest integer not less than $x$ (real part)
  610. cos(x)@radians@$cos~x$, cosine of $x$
  611. cosh(x)@any@$cosh~x$, hyperbolic cosine of $x$ in radians
  612. erf(x)@any@$erf ( roman real (x))$, error function of real ($x$)
  613. erfc(x)@any@$erfc ( roman real (x))$, 1.0 - error function of real ($x$)
  614. exp(x)@any@$e sup x$, exponential function of $x$
  615. floor(x)@any@$left floor x right floor$, largest integer not greater than $x$ (real part)
  616. gamma(x)@any@$GAMMA ( roman real (x))$, gamma function of real ($x$)
  617. ibeta(p,q,x)@any@$ibeta ( roman real (p,q,x))$, ibeta function of real ($p$,$q$,$x$)
  618. inverf(x)@any@inverse error function real($x$)
  619. igamma(a,x)@any@$igamma ( roman real (a,x))$, igamma function of real ($a$,$x$)
  620. imag(x)@complex@imaginary part of $x$ as a real number
  621. invnorm(x)@any@inverse normal distribution function real($x$)
  622. int(x)@real@integer part of $x$, truncated toward zero
  623. lgamma(x)@any@$lgamma ( roman real (x))$, lgamma function of real ($x$)
  624. log(x)@any@$ln~x$, natural logarithm (base $e$) of $x$
  625. log10(x)@any@${log sub 10}~x$, logarithm (base $10$) of $x$
  626. norm(x)@any@$norm(x)$, normal distribution function of real($x$)
  627. rand(x)@any@$rand ( roman real (x))$, pseudo random number generator
  628. real(x)@any@real part of $x$
  629. sgn(x)@any@1 if $x > 0$, -1 if $x < 0$, 0 if $x = 0$. $roman imag (x)$ ignored
  630. sin(x)@any@$sin~x$, sine of $x$
  631. sinh(x)@any@$sinh~x$, hyperbolic sine $x$ in radians
  632. sqrt(x)@any@$sqrt x $, square root of $x$
  633. tan(x)@any@$tan~x$, tangent of $x$
  634. tanh(x)@any@$tanh~x$, hyperbolic tangent of $x$ in radians
  635. .TE
  636. .KE
  637. .EQ
  638. delim off
  639. .EN
  640.  
  641.  
  642. A few additional functions are also available.
  643.  
  644.  
  645. .EQ
  646. delim $$
  647. .EN
  648. .KS
  649. .TS
  650. center box tab (@) ;
  651. c c l .
  652. Function@Arguments@Returns
  653. _
  654. column(x)@int@ column $x$ during datafile manipulation.
  655. tm_hour(x)@int@the hour
  656. tm_mday(x)@int@the day of the month
  657. tm_min(x)@int@the minute
  658. tm_mon(x)@int@the month
  659. tm_sec(x)@int@the second
  660. tm_wday(x)@int@the day of the week
  661. tm_yday(x)@int@the day of the year
  662. tm_year(x)@int@the year
  663. valid(x)@int@ test validity of column($x$) during datafile manip.
  664. .TE
  665. .KE
  666. .EQ
  667. delim off
  668. .EN
  669.  
  670. .sp 2
  671. .NH 2
  672. Operators
  673. .sp 1
  674. .LP
  675. .XS
  676. Operators
  677. .XE
  678. The operators in \fBgnuplot\fR are the same as the corresponding operators in the
  679. C programming language, except that all operators accept integer, real, and
  680. complex arguments, unless otherwise noted.  The ** operator (exponentiation)
  681. is supported, as in FORTRAN.
  682.  
  683. Parentheses may be used to change order of evaluation.
  684. .sp 2
  685. .RS
  686. .IP
  687. .NH 3
  688. Unary
  689. .sp 1
  690. .LP
  691. .XS
  692. Unary
  693. .XE
  694. The following is a list of all the unary operators and their usages:
  695.  
  696.  
  697. .EQ
  698. delim $$
  699. .EN
  700. .KS
  701. .TS
  702. center box tab (@) ;
  703. .TE
  704. .EQ
  705. delim off
  706. .EN
  707. .TS
  708. center box tab (@) ;
  709. c c l .
  710. Symbol@Example@Explanation
  711. _
  712. -@-a@unary minus
  713. +@+a@unary plus (no-operation)
  714. ~@~a@* one's complement
  715. !@!a@* logical negation
  716. !@a!@* factorial
  717. $@$3@* call arg/column during `using` manipulation
  718. _
  719. .TE
  720. .KE
  721. .EQ
  722. delim off
  723. .EN
  724.  
  725. (*) Starred explanations indicate that the operator requires an integer
  726. argument.
  727.  
  728. Operator precedence is the same as in Fortran and C.  As in those languages,
  729. parentheses may be used to change the order of operation.  Thus -2**2 = -4,
  730. but (-2)**2 = 4.
  731.  
  732. The factorial operator returns a real number to allow a greater range.
  733. .sp 2
  734. .NH 3
  735. Binary
  736. .sp 1
  737. .LP
  738. .XS
  739. Binary
  740. .XE
  741. The following is a list of all the binary operators and their usages:
  742.  
  743.  
  744. .EQ
  745. delim $$
  746. .EN
  747. .KS
  748. .TS
  749. center box tab (@) ;
  750. c c l .
  751. Symbol@Example@Explanation
  752. _
  753. **@a**b@exponentiation
  754. *@a*b@multiplication
  755. /@a/b@division
  756. %@a%b@* modulo
  757. +@a+b@addition
  758. -@a-b@subtraction
  759. ==@a==b@equality
  760. !=@a!=b@inequality
  761. <@a<b@less than
  762. <=@a<=b@less than or equal to
  763. >@a>b@greater than
  764. >=@a>=b@greater than or equal to
  765. &@a&b@* bitwise AND
  766. ^@a^b@* bitwise exclusive OR
  767. |@a|b@* bitwise inclusive OR
  768. &&@a&&b@* logical AND
  769. ||@a||b@* logical OR
  770. .TE
  771. .KE
  772. .EQ
  773. delim off
  774. .EN
  775.  
  776. (*) Starred explanations indicate that the operator requires integer
  777. arguments.
  778.  
  779. Logical AND (&&) and OR (||) short-circuit the way they do in C.  That is,
  780. the second \fB&&\fR operand is not evaluated if the first is false; the second
  781. \fB||\fR operand is not evaluated if the first is true.
  782. .sp 2
  783. .NH 3
  784. Ternary
  785. .sp 1
  786. .LP
  787. .XS
  788. Ternary
  789. .XE
  790. There is a single ternary operator:
  791.  
  792.  
  793. .EQ
  794. delim $$
  795. .EN
  796. .KS
  797. .TS
  798. center box tab (@) ;
  799. c c l .
  800. Symbol@Example@Explanation
  801. _
  802. ?:@a?b:c@* ternary operation
  803. .TE
  804. .KE
  805. .EQ
  806. delim off
  807. .EN
  808.  
  809. The ternary operator behaves as it does in C.  The first argument (a), which
  810. must be an integer, is evaluated.  If it is true (non-zero), the second
  811. argument (b) is evaluated and returned; otherwise the third argument (c) is
  812. evaluated and returned.
  813.  
  814. The ternary operator is very useful both in constructing piecewise functions
  815. and in plotting points only when certain conditions are met.
  816.  
  817. Examples:
  818.  
  819. Plot a function that is to equal sin(x) for 0 <= x < 1, 1/x for 1 <= x < 2,
  820. and undefined elsewhere:
  821. .br
  822.       f(x) = 0<=x && x<1 ? sin(x) : 1<=x && x<2 ? 1/x : 1/0
  823. .br
  824. .br
  825.       plot f(x)
  826. .br
  827. Note that \fBgnuplot\fR quietly ignores undefined values, so the final branch of
  828. the function (1/0) will produce no plottable points.  Note also that f(x)
  829. will be plotted as a continuous function across the discontinuity if a line
  830. style is used.  To plot it discontinuously, create separate functions for the
  831. two pieces.  (Parametric functions are also useful for this purpose.)
  832.  
  833. For data in a file, plot the average of the data in columns 2 and 3 against
  834. the datum in column 1, but only if the datum in column 4 is non-negative:
  835.  
  836. .br
  837.       plot 'file' using 1:( $4<0 ? 1/0 : ($2+$3)/2 )
  838. .br
  839.  
  840. Please see \fBplot data-file using\fR for an explanation of the \fBusing\fR syntax.
  841. .sp 2
  842. .RE
  843. .br
  844. .NH 2
  845. User-defined
  846. .sp 1
  847. .LP
  848. .XS
  849. User-defined
  850. .XE
  851. New user-defined variables and functions of one through five variables may
  852. be declared and used anywhere, including on the \fBplot\fR command itself.
  853.  
  854. User-defined function syntax:
  855. .br
  856.       <func-name>( <dummy1> {,<dummy2>} ... {,<dummy5>} ) = <expression>
  857. .br
  858.  
  859. where <expression> is defined in terms of <dummy1> through <dummy5>.
  860.  
  861. User-defined variable syntax:
  862. .br
  863.       <variable-name> = <constant-expression>
  864. .br
  865.  
  866. Examples:
  867. .br
  868.       w = 2
  869. .br
  870. .br
  871.       q = floor(tan(pi/2 - 0.1))
  872. .br
  873. .br
  874.       f(x) = sin(w*x)
  875. .br
  876. .br
  877.       sinc(x) = sin(pi*x)/(pi*x)
  878. .br
  879. .br
  880.       delta(t) = (t == 0)
  881. .br
  882. .br
  883.       ramp(t) = (t > 0) ? t : 0
  884. .br
  885. .br
  886.       min(a,b) = (a < b) ? a : b
  887. .br
  888. .br
  889.       comb(n,k) = n!/(k!*(n-k)!)
  890. .br
  891. .br
  892.       len3d(x,y,z) = sqrt(x*x+y*y+z*z)
  893. .br
  894. .br
  895.       plot f(x) = sin(x*a), a = 0.2, f(x), a = 0.4, f(x)
  896. .br
  897.  
  898. Note that the variable \fBpi\fR is already defined.  But it is in no way magic;
  899. you may redefine it to be whatever you like.
  900.  
  901. Valid names are the same as in most programming languages: they must begin
  902. with a letter, but subsequent characters may be letters, digits, "$", or "_".
  903. Note, however, that the \fBfit\fR mechanism uses several variables with names
  904. that begin "FIT_".  It is safest to avoid using such names.  "FIT_LIMIT",
  905. however, is one that you may wish to redefine. See the documentation
  906. on \fBfit\fR for details.
  907.  
  908.  
  909. See \fBshow functions\fR, \fBshow variables\fR, and \fBfit\fR.
  910. .sp 2
  911. .RE
  912. .br
  913. .NH 1
  914. Glossary
  915. .sp 1
  916. .LP
  917. .XS
  918. Glossary
  919. .XE
  920. Throughout this document an attempt has been made to maintain consistency of
  921. nomenclature.  This cannot be wholly successful because as \fBgnuplot\fR has
  922. evolved over time, certain command and keyword names have been adopted that
  923. preclude such perfection.  This section contains explanations of the way
  924. some of these terms are used.
  925.  
  926. A "page" or "screen" is the entire area addressable by \fBgnuplot\fR.  On a
  927. monitor, it is the full screen; on a plotter, it is a single sheet of paper.
  928.  
  929. A screen may contain one or more "plots".  A plot is defined by an abscissa
  930. and an ordinate, although these need not actually appear on it, as well as
  931. the margins and any text written therein.
  932.  
  933. A plot contains one "graph".  A graph is defined by an abscissa and an
  934. ordinate, although these need not actually appear on it.
  935.  
  936. A graph may contain one or more "lines".  A line is a single function or
  937. data set.  "Line" is also a plotting style.  The word will also be used in
  938. sense "a line of text".  Presumably the context will remove any ambiguity.
  939.  
  940. The lines on a graph may have individual names.  These may be listed
  941. together with a sample of the plotting style used to represent them in
  942. the "key", sometimes also called the "legend".
  943.  
  944. The word "title" occurs with multiple meanings in \fBgnuplot\fR.  In this
  945. document, it will always be preceded by the adjective "plot", "line", or
  946. "key" to differentiate among them.
  947.  
  948. A graph may have up to four labelled axes.  Various commands have the name of
  949. an axis built into their names, such as \fBset xlabel\fR.  Other commands have
  950. one or more axis names as options, such as \fBset logscale xy\fR.  The names of
  951. the four axes for these usages are "x" for the axis along the bottom border
  952. of the plot, "y" for the left border, "x2" for the top border, and "y2" for
  953. the right border.  "z" also occurs in commands used with 3-d plotting.
  954.  
  955. When discussing data files, the term "record" will be resurrected and used
  956. to denote a single line of text in the file, that is, the characters between
  957. newline or end-of-record characters.  A "point" is the datum extracted from
  958. a single record.  A "datablock" is a set of points from consecutive records,
  959. delimited by blank records.  A line, when referred to in the context of a
  960. data file, is a subset of a datablock.
  961. .sp 2
  962. .NH 1
  963. Plotting
  964. .sp 1
  965. .LP
  966. .XS
  967. Plotting
  968. .XE
  969. There are three \fBgnuplot\fR commands which actually create a plot: \fBplot\fR,
  970. \fBsplot\fR and \fBreplot\fR.  \fBplot\fR generates 2-d plots, \fBsplot\fR generates 3-d
  971. plots (actually 2-d projections, of course), and \fBreplot\fR appends its
  972. arguments to the previous \fBplot\fR or \fBsplot\fR and executes the modified
  973. command.
  974.  
  975. Much of the general information about plotting can be found in the discussion
  976. of \fBplot\fR; information specific to 3-d can be found in the \fBsplot\fR section.
  977.  
  978. \fBplot\fR operates in either rectangular or polar coordinates -- see \fBset polar\fR
  979. for details of the latter.  \fBsplot\fR operates only in rectangular coordinates,
  980. but the \fBset mapping\fR command allows for a few other coordinate systems to be
  981. treated.  In addition, the \fBusing\fR option allows both \fBplot\fR and \fBsplot\fR to
  982. treat almost any coordinate system you\&'d care to define.
  983.  
  984. \fBsplot\fR can plot surfaces and contours in addition to points and/or lines.
  985. In addition to \fBsplot\fR, see \fBset isosamples\fR for information about defining
  986. the grid for a 3-d function;  \fBsplot datafile\fR for information about the
  987. requisite file structure for 3-d data values; and \fBset contour\fR and \fBset
  988. cntrparam\fR for information about contours.
  989. .sp 2
  990. .NH 1
  991. Start-up
  992. .sp 1
  993. .LP
  994. .XS
  995. Start-up
  996. .XE
  997. When \fBgnuplot\fR is run, it looks for an initialization file to load.  This
  998. file is called \fB.gnuplot\fR on Unix and AmigaOS systems, and \fBGNUPLOT.INI\fR on
  999. other systems.  If this file is not found in the current directory, the
  1000. program will look for it in the home directory (under AmigaOS,
  1001. Atari(single)TOS, MS-DOS and OS/2, the environment variable \fBgnuplot\fR should
  1002. contain the name of this directory).  Note: if NOCWDRC is defined during the
  1003. installation, \fBgnuplot\fR will not read from the current directory.
  1004.  
  1005. If the initialization file is found, \fBgnuplot\fR executes the commands in it.
  1006. These may be any legal \fBgnuplot\fR commands, but typically they are limited to
  1007. setting the terminal and defining frequently-used functions or variables.
  1008. .sp 2
  1009. .NH 1
  1010. Substitution
  1011. .sp 1
  1012. .LP
  1013. .XS
  1014. Substitution
  1015. .XE
  1016. Command-line substitution is specified by a system command enclosed in
  1017. backquotes.  This command is spawned and the output it produces replaces
  1018. the name of the command (and backquotes) on the command line.  Some
  1019. implementations also support pipes;  see \fBplot data-file special-filenames\fR.
  1020.  
  1021. Newlines in the output produced by the spawned command are replaced with
  1022. blanks.
  1023.  
  1024. Command-line substitution can be used anywhere on the \fBgnuplot\fR command
  1025. line.
  1026.  
  1027. Example:
  1028.  
  1029. This will run the program \fBleastsq\fR and replace \fBleastsq\fR (including
  1030. backquotes) on the command line with its output:
  1031. .br
  1032.       f(x) = `leastsq`
  1033. .br
  1034.  
  1035. or, in VMS
  1036. .br
  1037.       f(x) = `run leastsq`
  1038. .br
  1039. .sp 2
  1040. .NH 1
  1041. Syntax
  1042. .sp 1
  1043. .LP
  1044. .XS
  1045. Syntax
  1046. .XE
  1047. The general rules of syntax and punctuation in \fBgnuplot\fR are that keywords
  1048. and options are order-dependent.  Options and any accompanying parameters are
  1049. separated by spaces whereas lists and coordinates are separated by commas.
  1050. Ranges are separated by colons and enclosed in brackets [], text and file
  1051. names are enclosed in quotes, and a few miscellaneous things are enclosed
  1052. in parentheses.  Braces {} are used for a few special purposes.
  1053.  
  1054. Commas are used to separate coordinates on the \fBset\fR commands \fBarrow\fR,
  1055. \fBkey\fR, and \fBlabel\fR; the list of variables being fitted (the list after the
  1056. \fBvia\fR keyword on the \fBfit\fR command); lists of discrete contours or the loop
  1057. parameters which specify them on the \fBset cntrparam\fR command; the arguments
  1058. of the \fBset\fR commands \fBdgrid3d\fR, \fBdummy\fR, \fBisosamples\fR, \fBoffsets\fR, \fBorigin\fR,
  1059. \fBsamples\fR, \fBsize\fR, \fBtime\fR, and \fBview\fR; lists of tics or the loop parameters
  1060. which specify them; the offsets for titles and axis labels; parametric
  1061. functions to be used to calculate the x, y, and z coordinates on the \fBplot\fR,
  1062. \fBreplot\fR and \fBsplot\fR commands; and the complete sets of keywords specifying
  1063. individual plots (data sets or functions) on the \fBplot\fR, \fBreplot\fR and \fBsplot\fR
  1064. commands.
  1065.  
  1066. Parentheses are used to delimit sets of explicit tics (as opposed to loop
  1067. parameters) and to indicate computations in the \fBusing\fR filter of the \fBfit\fR,
  1068. \fBplot\fR, \fBreplot\fR and \fBsplot\fR commands.
  1069.  
  1070. (Parentheses and commas are also used as usual in function notation.)
  1071.  
  1072. Brackets are used to delimit ranges, whether they are given on \fBset\fR, \fBplot\fR
  1073. or \fBsplot\fR commands.
  1074.  
  1075. Colons are used to separate extrema in \fBrange\fR specifications (whether they
  1076. are given on \fBset\fR, \fBplot\fR or \fBsplot\fR commands) and to separate entries in
  1077. the \fBusing\fR filter of the \fBplot\fR, \fBreplot\fR, \fBsplot\fR and \fBfit\fR commands.
  1078.  
  1079. Semicolons are used to separate commands given on a single command line.
  1080.  
  1081. Braces are used in text to be specially processed by some terminals, like
  1082. \fBpostscript\fR.  They are also used to denote complex numbers: {3,2} = 3 + 2i.
  1083.  
  1084. Text may be enclosed in single- or double-quotes.  Backslash processing of
  1085. sequences like \\n (newline) and \\345 (octal character code) is performed for
  1086. double-quoted strings, but not for single-quoted strings.
  1087.  
  1088. The justification is the same for each line of a multi-line string.  Thus the
  1089. center-justified string
  1090. .br
  1091.       "This is the first line of text.\\nThis is the second line."
  1092. .br
  1093. will produce
  1094. .br
  1095.                        This is the first line of text.
  1096. .br
  1097. .br
  1098.                           This is the second line.
  1099. .br
  1100. but
  1101. .br
  1102.       'This is the first line of text.\\nThis is the second line.'
  1103. .br
  1104. will produce
  1105. .br
  1106.           This is the first line of text.\\nThis is the second line.
  1107. .br
  1108.  
  1109. Filenames may be entered with either single- or double-quotes.  In this
  1110. manual the command examples generally single-quote filenames and double-quote
  1111. other string tokens for clarity.
  1112.  
  1113. At present you should not embed \\n inside {} when using the enhanced option
  1114. of the postscript terminal.
  1115.  
  1116. The EEPIC, Imagen, Uniplex, LaTeX, and TPIC drivers allow a newline to be
  1117. specified by \\\\ in a single-quoted string or \\\\\\\\ in a double-quoted string.
  1118.  
  1119. Back-quotes are used to enclose system commands for substitution.
  1120. .sp 2
  1121. .NH 1
  1122. Time/Date data
  1123. .sp 1
  1124. .LP
  1125. .XS
  1126. Time/Date data
  1127. .XE
  1128. \fBgnuplot\fR supports the use of time and/or date information as input data.
  1129. This feature is activated by the commands \fBset xdata time\fR, \fBset ydata time\fR,
  1130. etc.
  1131.  
  1132. Internally all times and dates are converted to the number of seconds from
  1133. the year 2000.  The command \fBset timefmt\fR defines the format for all inputs:
  1134. data files, ranges, tics, label positions---in short, anything that accepts a
  1135. data value must receive it in this format.  Since only one input format can
  1136. be in force at a given time, all time/date quantities being input at the same
  1137. time must be presented in the same format.  Thus if both x and y data in a
  1138. file are time/date, they must be in the same format.
  1139.  
  1140. The conversion to and from seconds assumes Universal Time (which is the same
  1141. as Greenwich Standard Time).  There is no provision for changing the time
  1142. zone or for daylight savings.  If all your data refer to the same time zone
  1143. (and are all either daylight or standard) you don\&'t need to worry about these
  1144. things.  But if the absolute time is crucial for your application, you\&'ll
  1145. need to convert to UT yourself.
  1146.  
  1147. Commands like \fBshow xrange\fR will re-interpret the integer according to
  1148. \fBtimefmt\fR.  If you change \fBtimefmt\fR, and then \fBshow\fR the quantity again, it
  1149. will be displayed in the new \fBtimefmt\fR.  For that matter, if you give the
  1150. deactivation command (like \fBset xdata\fR), the quantity will be shown in its
  1151. numerical form.
  1152.  
  1153. The command \fBset format\fR defines the format that will be used for tic labels,
  1154. whether or not the specified axis is time/date.
  1155.  
  1156. If time/date information is to be plotted from a file, the \fBusing\fR option
  1157. _must_ be used on the \fBplot\fR or \fBsplot\fR command.  These commands simply use
  1158. white space to separate columns, but white space may be embedded within the
  1159. time/date string.  If you use tabs as a separator, some trial-and-error may
  1160. be necessary to discover how your system treats them.
  1161.  
  1162. The following example demonstrates time/date plotting.
  1163.  
  1164. Suppose the file "data" contains records like
  1165.  
  1166. .br
  1167.       03/21/95 10:00  6.02e23
  1168. .br
  1169.  
  1170. This file can be plotted by
  1171.  
  1172. .br
  1173.       set xdata time
  1174. .br
  1175. .br
  1176.       set timefmt "%m/%d/%y"
  1177. .br
  1178. .br
  1179.       set xrange ["03/21/95":"03/22/95"]
  1180. .br
  1181. .br
  1182.       set format x "%m/%d"
  1183. .br
  1184. .br
  1185.       set timefmt "%m/%d/%y %H:%M"
  1186. .br
  1187. .br
  1188.       plot "data" using 1:3
  1189. .br
  1190.  
  1191. which will produce xtic labels that look like "03/21".
  1192.  
  1193. See the descriptions of each command for more details.
  1194. .sp 3
  1195. .NH 1
  1196. Commands
  1197. .sp 1
  1198. .LP
  1199. .XS
  1200. Commands
  1201. .XE
  1202. This section lists the commands acceptable to \fBgnuplot\fR in alphabetical
  1203. order.  Printed versions of this document contain all commands; on-line
  1204. versions may not be complete.  Indeed, on some systems there may be no
  1205. commands at all listed under this heading.
  1206.  
  1207. Note that in most cases unambiguous abbreviations for command names and their
  1208. options are permissible, i.e., "\fBp f(x) w l\fR" instead of "\fBplot f(x) with
  1209. lines\fR".
  1210.  
  1211. In the syntax descriptions, braces ({}) denote optional arguments and a
  1212. vertical bar (|) separates mutually exclusive choices.
  1213. .sp 2
  1214. .NH 1
  1215. Cd
  1216. .sp 1
  1217. .LP
  1218. .XS
  1219. Cd
  1220. .XE
  1221. The \fBcd\fR command changes the working directory.
  1222.  
  1223. Syntax:
  1224. .br
  1225.       cd '<directory-name>'
  1226. .br
  1227.  
  1228. The directory name must be enclosed in quotes.
  1229.  
  1230. Examples:
  1231. .br
  1232.       cd 'subdir'
  1233. .br
  1234. .br
  1235.       cd ".."
  1236. .br
  1237.  
  1238. DOS users _must_ use single-quotes---backslash [\\] has special significance
  1239. inside double-quotes.  For example,
  1240. .br
  1241.       cd "c:\\newdata"
  1242. .br
  1243. fails, but
  1244. .br
  1245.       cd 'c:\\newdata'
  1246. .br
  1247. works as expected.
  1248. .sp 2
  1249. .NH 1
  1250. Call
  1251. .sp 1
  1252. .LP
  1253. .XS
  1254. Call
  1255. .XE
  1256. The \fBcall\fR command is identical to the load command with one exception: you
  1257. can have up to ten additional parameters to the command (delimited according
  1258. to the standard parser rules) which can be substituted into the lines read
  1259. from the file.  As each line is read from the \fBcall\fRed input file, it is
  1260. scanned for the sequence \fB$\fR (dollar-sign) followed by a digit (0--9).  If
  1261. found, the sequence is replaced by the corresponding parameter from the
  1262. \fBcall\fR command line.  If the parameter was specified as a string in the
  1263. \fBcall\fR line, it is substituted without its enclosing quotes.  \fB$\fR followed by
  1264. any character other than a digit will be that character.  E.g. use \fB$$\fR to
  1265. get a single \fB$\fR.  Providing more than ten parameters on the \fBcall\fR command
  1266. line will cause an error.  A parameter that was not provided substitutes as
  1267. nothing.  Files being \fBcall\fRed may themselves contain \fBcall\fR or \fBload\fR
  1268. commands.
  1269.  
  1270. The \fBcall\fR command _must_ be the last command on a multi-command line.
  1271.  
  1272. Syntax:
  1273. .br
  1274.       call "<input-file>" <parameter-0> <parm-1> ... <parm-9>
  1275. .br
  1276.  
  1277. The name of the input file must be enclosed in quotes, and it is recommended
  1278. that parameters are similarly enclosed in quotes (future versions of gnuplot
  1279. may treat quoted and unquoted arguments differently).
  1280.  
  1281. Example:
  1282.  
  1283. If the file \&'calltest.gp\&' contains the line:
  1284. .br
  1285.       print "p0=$0 p1=$1 p2=$2 p3=$3 p4=$4 p5=$5 p6=$6 p7=x$7x"
  1286. .br
  1287.  
  1288. entering the command:
  1289. .br
  1290.       call 'calltest.gp' "abcd" 1.2 + "'quoted'" -- "$2"
  1291. .br
  1292.  
  1293. will display:
  1294. .br
  1295.       p0=abcd p1=1.2 p2=+ p3='quoted' p4=- p5=- p6=$2 p7=xx
  1296. .br
  1297.  
  1298. NOTE: there is a clash in syntax with the datafile \fBusing\fR callback
  1299. operator.  Use \fB$$n\fR or \fBcolumn(n)\fR to access column n from a datafile inside
  1300. a \fBcall\fRed datafile plot.
  1301. .sp 2
  1302. .NH 1
  1303. Clear
  1304. .sp 1
  1305. .LP
  1306. .XS
  1307. Clear
  1308. .XE
  1309. The \fBclear\fR command erases the current screen or output device as specified
  1310. by \fBset output\fR.  This usually generates a formfeed on hardcopy devices.  Use
  1311. \fBset terminal\fR to set the device type.
  1312.  
  1313. For some terminals \fBclear\fR erases only the portion of the plotting surface
  1314. defined by \fBset size\fR, so for these it can be used in conjunction with \fBset
  1315. multiplot\fR to create an inset.
  1316.  
  1317. Example:
  1318. .br
  1319.       set multiplot
  1320. .br
  1321. .br
  1322.       plot sin(x)
  1323. .br
  1324. .br
  1325.       set origin 0.5,0.5
  1326. .br
  1327. .br
  1328.       set size 0.4,0.4
  1329. .br
  1330. .br
  1331.       clear
  1332. .br
  1333. .br
  1334.       plot cos(x)
  1335. .br
  1336. .br
  1337.       set nomultiplot
  1338. .br
  1339.  
  1340. Please see \fBset multiplot\fR, \fBset size\fR, and \fBset origin\fR for details of these
  1341. commands.
  1342. .sp 2
  1343. .NH 1
  1344. Exit
  1345. .sp 1
  1346. .LP
  1347. .XS
  1348. Exit
  1349. .XE
  1350. The commands \fBexit\fR and \fBquit\fR and the END-OF-FILE character will exit the
  1351. current \fBgnuplot\fR command file and \fBload\fR the next one.  See "help
  1352. batch/interactive" for more details.
  1353.  
  1354. Each of these commands will clear the output device (as does the \fBclear\fR
  1355. command) before exiting.
  1356. .sp 2
  1357. .NH 1
  1358. Fit
  1359. .sp 1
  1360. .LP
  1361. .XS
  1362. Fit
  1363. .XE
  1364. The \fBfit\fR command can fit a user-defined function to a set of data points
  1365. (x,y) or (x,y,z), using an implementation of the nonlinear least-squares
  1366. (NLLS) Marquardt-Levenberg algorithm.  Any user-defined variable occurring in
  1367. the function body may serve as a fit parameter, but the return type of the
  1368. function must be real.
  1369.  
  1370. Syntax:
  1371. .br
  1372.       fit {[xrange] {[yrange]}} <function> '<datafile>'
  1373. .br
  1374. .br
  1375.           {datafile-modifiers}
  1376. .br
  1377. .br
  1378.           via '<parameter file>' | <var1>{,<var2>,...}
  1379. .br
  1380.  
  1381. Ranges may be specified to temporarily limit the data which is to be fitted;
  1382. any out-of-range data points are ignored. The syntax is
  1383. .br
  1384.       [{dummy_variable=}{<min>}{:<max>}],
  1385. .br
  1386. analogous to \fBplot\fR; see \fBplot ranges\fR.
  1387.  
  1388. <function> is any valid \fBgnuplot\fR expression, although it is usual to use a
  1389. previously user-defined function of the form f(x) or f(x,y).
  1390.  
  1391. <datafile> is treated as in the \fBplot\fR command.  All the \fBplot datafile\fR
  1392. modifiers (\fBusing\fR, \fBevery\fR,...) except \fBsmooth\fR are applicable to \fBfit\fR.
  1393. See \fBplot datafile\fR.
  1394.  
  1395. The default data formats for fitting functions with a single independent
  1396. variable, y=f(x), are {x:}y or x:y:s; those formats can be changed with
  1397. the datafile \fBusing\fR qualifier.  The third item, (a column number or an
  1398. expression), if present, is interpreted as the standard deviation of the
  1399. corresponding y value and is used to compute a weight for the datum, 1/s**2.
  1400. Otherwise, all data points are weighted equally, with a weight of one.
  1401.  
  1402. To fit a function with two independent variables, z=f(x,y), the required
  1403. format is \fBusing\fR with four items, x:y:z:s.  The complete format must be
  1404. given---no default columns are assumed for a missing token.  Weights for
  1405. each data point are evaluated from \&'s\&' as above.  If error estimates are
  1406. not available, a constant value can be specified as a constant expression
  1407. (see \fBplot datafile using\fR), e.g., \fBusing 1:2:3:(1)\fR.
  1408.  
  1409. Multiple datasets may be simultaneously fit with functions of one
  1410. independent variable by making y a \&'pseudo-variable\&', e.g., the dataline
  1411. number, and fitting as two independent variables.  See \fBfit multibranch\fR.
  1412.  
  1413. The \fBvia\fR qualifier specifies which parameters are to be adjusted, either
  1414. directly, or by referencing a parameter file.
  1415.  
  1416. Examples:
  1417. .br
  1418.       f(x) = a*x**2 + b*x + c
  1419. .br
  1420. .br
  1421.       g(x,y) = a*x**2 + b*y**2 + c*x*y
  1422. .br
  1423. .br
  1424.       FIT_LIMIT = 1e-6
  1425. .br
  1426. .br
  1427.       fit f(x) 'measured.dat' via 'start.par'
  1428. .br
  1429. .br
  1430.       fit f(x) 'measured.dat' using 3:($7-5) via 'start.par'
  1431. .br
  1432. .br
  1433.       fit f(x) './data/trash.dat' using 1:2:3 via a, b, c
  1434. .br
  1435. .br
  1436.       fit g(x,y) 'surface.dat' using 1:2:3:(1) via a, b, c
  1437. .br
  1438.  
  1439. After each iteration step, detailed information about the current state
  1440. of the fit is written to the display.  The same information about the
  1441. initial and final states is written to a log file, "fit.log".  This file
  1442. is always appended to, so as to not lose any previous fit history;  it
  1443. should be deleted or renamed as desired.
  1444.  
  1445. The fit may be interrupted by pressing Ctrl-C (any key but Ctrl-C under
  1446. MSDOS and Atari Multitasking Systems).  After the current iteration
  1447. completes, you have the option to (1) stop the fit and accept the current
  1448. parameter values, (2) continue the fit, (3) execute a \fBgnuplot\fR command
  1449. as specified by the environment variable FIT_SCRIPT.  The default for
  1450. FIT_SCRIPT is \fBreplot\fR, so if you had previously plotted both the data
  1451. and the fitting function in one graph, you can display the current state
  1452. of the fit.
  1453.  
  1454. Once \fBfit\fR has finished, the \fBupdate\fR command may be used to store final
  1455. values in a file for subsequent use as a parameter file.   See \fBupdate\fR
  1456. for details.
  1457. .sp 2
  1458. .RS
  1459. .IP
  1460. .NH 2
  1461. Adjustable parameters
  1462. .sp 1
  1463. .LP
  1464. .XS
  1465. Adjustable parameters
  1466. .XE
  1467. There are two ways that \fBvia\fR can specify the parameters to be adjusted,
  1468. either directly on the command line or indirectly, by referencing a
  1469. parameter file.  The two use different means to set initial values.
  1470.  
  1471. Adjustable parameters can be specified by a comma-separated list of variable
  1472. names after the \fBvia\fR keyword.  Any variable that is not already defined is
  1473. is created with an initial value of 1.0.  However, the fit is more likely
  1474. to converge rapidly if the variables have been previously declared with more
  1475. appropriate starting values.
  1476.  
  1477. In a parameter file, each parameter to be varied and a corresponding initial
  1478. value are specified, one per line, in the form
  1479. .br
  1480.       varname = value
  1481. .br
  1482.  
  1483. Comments, marked by \&'#\&', and blank lines are permissible.  The
  1484. special form
  1485. .br
  1486.       varname = value       # FIXED
  1487. .br
  1488.  
  1489. means that the variable is treated as a \&'fixed parameter\&', initialized by the
  1490. parameter file, but not adjusted by \fBfit\fR.  For clarity, it may be useful to
  1491. designate variables as fixed parameters so that their values are reported by
  1492. \fBfit\fR.  The keyword \fB# FIXED\fR has to appear in exactly this form.
  1493.  
  1494. .sp 2
  1495. .NH 2
  1496. Beginner's guide
  1497. .sp 1
  1498. .LP
  1499. .XS
  1500. Beginner's guide
  1501. .XE
  1502. \fBfit\fR is used to find a set of parameters that \&'best\&' fits your data to your
  1503. user-defined function.  The fit is judged on the basis of the the sum of the
  1504. squared differences or \&'residuals\&' (SSR) between the input data points and
  1505. the function values, evaluated at the same places.  This quantity is often
  1506. called \&'chisquare\&' (i.e., the Greek letter chi, to the power of 2).  The
  1507. algorithm attempts to minimize SSR, or more precisely, WSSR, as the residuals
  1508. are \&'weighted\&' by the input data errors (or 1.0) before being squared; see
  1509. \fBfit error_estimates\fR for details.
  1510.  
  1511. That\&'s why it is called \&'least-squares fitting\&'.  Let\&'s look at an example
  1512. to see what is meant by \&'non-linear\&', but first we had better go over some
  1513. terms.  Here it is convenient to use z as the dependent variable for
  1514. user-defined functions of either one independent variable, z=f(x), or two
  1515. independent variables, z=f(x,y).  A parameter is a user-defined variable
  1516. that \fBfit\fR will adjust, i.e., an unknown quantity in the function
  1517. declaration.  Linearity/non-linearity refers to the relationship of the
  1518. dependent variable, z, to the parameters which \fBfit\fR is adjusting, not of
  1519. z to the independent variables, x and/or y.  (To be technical, the
  1520. second {and higher} derivatives of the fitting function with respect to
  1521. the parameters are zero for a linear least-squares problem).
  1522.  
  1523. For linear least-squares (LLS), the user-defined function will be a sum of
  1524. simple functions, not involving any parameters, each multiplied by one
  1525. parameter.  NLLS handles more complicated functions in which parameters can
  1526. be used in a large number of ways.  An example that illustrates the
  1527. difference between linear and nonlinear least-squares is the Fourier series.
  1528. One member may be written as
  1529. .br
  1530.      z=a*sin(c*x) + b*cos(c*x).
  1531. .br
  1532. If a and b are the unknown parameters and c is constant, then estimating
  1533. values of the parameters is a linear least-squares problem.  However, if
  1534. c is an unknown parameter, the problem is nonlinear.
  1535.  
  1536. In the linear case, parameter values can be determined by comparatively
  1537. simple linear algebra, in one direct step.  However LLS is a special case
  1538. which is also solved along with more general NLLS problems by the iterative
  1539. procedure that \fBgnuplot\fR uses.  \fBfit\fR attempts to find the minimum by doing
  1540. a search.  Each step (iteration) calculates WSSR with a new set of parameter
  1541. values.  The Marquardt-Levenberg algorithm selects the parameter values for
  1542. the next iteration.  The process continues until a preset criterium is met,
  1543. either (1) the fit has "converged" (the relative change in WSSR is less than
  1544. FIT_LIMIT), or (2) it reaches a preset iteration count limit, FIT_MAXITER
  1545. (see \fBfit control variables\fR).  The fit may also be interrupted
  1546. and subsequently halted from the keyboard (see \fBfit\fR).
  1547.  
  1548. Often the function to be fitted will be based on a model (or theory) that
  1549. attempts to describe or predict the behaviour of the data.  Then \fBfit\fR can
  1550. be used to find values for the free parameters of the model, to determine
  1551. how well the data fits the model, and to estimate an error range for each
  1552. parameter.  See \fBfit error_estimates\fR.
  1553.  
  1554. Alternatively, in curve-fitting, functions are selected independent of
  1555. a model (on the basis of experience as to which are likely to describe
  1556. the trend of the data with the desired resolution and a minimum number
  1557. of parameters*functions.)  The \fBfit\fR solution then provides an analytic
  1558. representation of the curve.
  1559.  
  1560. However, if all you really want is a smooth curve through your data points,
  1561. the \fBsmooth\fR option to \fBplot\fR may be what you\&'ve been looking for rather
  1562. than \fBfit\fR.
  1563. .sp 2
  1564. .NH 2
  1565. Error estimates
  1566. .sp 1
  1567. .LP
  1568. .XS
  1569. Error estimates
  1570. .XE
  1571. In \fBfit\fR, the term "error" is used in two different contexts, data error
  1572. estimates and parameter error estimates.
  1573.  
  1574. Data error estimates are used to calculate the relative weight of each data
  1575. point when determining the weighted sum of squared residuals, WSSR or
  1576. chisquare.  They can affect the parameter estimates, since they determine
  1577. how much influence the deviation of each data point from the fitted function
  1578. has on the final values.  Some of the \fBfit\fR output information, including
  1579. the parameter error estimates, is more meaningful if accurate data error
  1580. estimates have been provided.
  1581.  
  1582. The \&'statistical overview\&' describes some of the \fBfit\fR output and gives some
  1583. background for the \&'practical guidelines\&'.
  1584. .sp 2
  1585. .RS
  1586. .IP
  1587. .NH 3
  1588. Statistical overview
  1589. .sp 1
  1590. .LP
  1591. .XS
  1592. Statistical overview
  1593. .XE
  1594. The theory of non-linear least-squares (NLLS) is generally described in terms
  1595. of a normal distribution of errors, that is, the input data is assumed to be
  1596. a sample from a population having a given mean and a Gaussian (normal)
  1597. distribution about the mean with a given standard deviation.  For a sample of
  1598. sufficiently large size, and knowing the population standard deviation, one
  1599. can use the statistics of the chisquare distribution to describe a "goodness
  1600. of fit" by looking at the variable often called "chisquare".  Here, it is
  1601. sufficient to say that a reduced chisquare (chisquare/degrees of freedom,
  1602. where degrees of freedom is the number of datapoints less the number of
  1603. parameters being fitted) of 1.0 is an indication that the weighted sum of
  1604. squared deviations between the fitted function and the data points is the
  1605. same as that expected for a random sample from a population characterized by
  1606. the function with the current value of the parameters and the given standard
  1607. deviations.
  1608.  
  1609. If the standard deviation for the population is not constant, as in counting
  1610. statistics where variance = counts, then each point should be individually
  1611. weighted when comparing the observed sum of deviations and the expected sum
  1612. of deviations.
  1613.  
  1614. At the conclusion \fBfit\fR reports \&'stdfit\&', the standard deviation of the fit,
  1615. which is the rms of the residuals, and the variance of the residuals, also
  1616. called \&'reduced chisquare\&' when the data points are weighted.  The number of
  1617. degrees of freedom (the number of data points minus the number of fitted
  1618. parameters) is used in these estimates because the parameters used in
  1619. calculating the residuals of the datapoints were obtained from the same data.
  1620.  
  1621. To estimate confidence levels for the parameters, one can use the minimum
  1622. chisquare obtained from the fit and chisquare statistics to determine the
  1623. value of chisquare corresponding to the desired confidence level, but
  1624. considerably more calculation is required to determine the combinations of
  1625. parameters which produce such values.
  1626.  
  1627. Rather than determine confidence intervals, \fBfit\fR reports parameter error
  1628. estimates which are readily obtained from the variance-covariance matrix
  1629. after the final iteration.  By convention, these estimates are called
  1630. "standard errors" or "asymptotic standard errors", since they are calculated
  1631. in the same way as the standard errors (standard deviation of each parameter)
  1632. of a linear least-squares problem, even though the statistical conditions for
  1633. designating the quantity calculated to be a standard deviation are not
  1634. generally valid for the NLLS problem.  The asymptotic standard errors are
  1635. generally over-optimistic and should not be used for determining confidence
  1636. levels, but are useful for qualitative purposes.
  1637.  
  1638. The final solution also produces a correlation matrix, which gives an
  1639. indication of the correlation of parameters in the region of the solution;
  1640. if one parameter is changed, increasing chisquare, does changing another
  1641. compensate?  The main diagonal elements, autocorrelation, are all 1; if
  1642. all parameters were independent, all other elements would be nearly 0.  Two
  1643. variables which completely compensate each other would have an off-diagonal
  1644. element of unit magnitude, with a sign depending on whether the relation is
  1645. proportional or inversely proportional.  The smaller the magnitudes of the
  1646. off-diagonal elements, the closer the estimates of the standard deviation
  1647. of each parameter would be to the asymptotic standard error.
  1648. .sp 2
  1649. .NH 3
  1650. Practical guidelines
  1651. .sp 1
  1652. .LP
  1653. .XS
  1654. Practical guidelines
  1655. .XE
  1656. If you have a basis for assigning weights to each data point, doing so lets
  1657. you make use of additional knowledge about your measurements, e.g., take into
  1658. account that some points may be more reliable than others.  That may affect
  1659. the final values of the parameters.
  1660.  
  1661. Weighting the data provides a basis for interpreting the additional \fBfit\fR
  1662. output after the last iteration.  Even if you weight each point equally,
  1663. estimating an average standard deviation rather than using a weight of 1
  1664. makes WSSR a dimensionless variable, as chisquare is by definition.
  1665.  
  1666. Each fit iteration will display information which can be used to evaluate
  1667. the progress of the fit.  (An \&'*\&' indicates that it did not find a smaller
  1668. WSSR and is trying again.)  The \&'sum of squares of residuals\&', also called
  1669. \&\&'chisquare\&', is the WSSR between the data and your fitted function; \fBfit\fR
  1670. has minimized that.  At this stage, with weighted data, chisquare is expected
  1671. to approach the number of degrees of freedom (data points minus parameters).
  1672. The WSSR can be used to calculate the reduced chisquare (WSSR/ndf) or stdfit,
  1673. the standard deviation of the fit, sqrt(WSSR/ndf).  Both of these are
  1674. reported for the final WSSR.
  1675.  
  1676. If the data are unweighted, stdfit is the rms value of the deviation of the
  1677. data from the fitted function, in user units.
  1678.  
  1679. If you supplied valid data errors, the number of data points is large enough,
  1680. and the model is correct, the reduced chisquare should be about unity.  (For
  1681. details, look up the \&'chi-squared distribution\&' in your favourite statistics
  1682. reference.)  If so, there are additional tests, beyond the scope of this
  1683. overview, for determining how well the model fits the data.
  1684.  
  1685. A reduced chisquare much larger than 1.0 may be due to incorrect data error
  1686. estimates, data errors not normally distributed, systematic measurement
  1687. errors, \&'outliers\&', or an incorrect model function.  A plot of the residuals,
  1688. e.g., \fBplot \&'datafile\&' using 1:($2-f($1))\fR, may help to show any systematic
  1689. trends.  Plotting both the data points and the function may help to suggest
  1690. another model.
  1691.  
  1692. Similarly, a reduced chisquare less than 1.0 indicates WSSR is less than that
  1693. expected for a random sample from the function with normally distributed
  1694. errors.  The data error estimates may be too large, the statistical
  1695. assumptions may not be justified, or the model function may be too general,
  1696. fitting fluctuations in a particular sample in addition to the underlying
  1697. trends.  In the latter case, a simpler function may be more appropriate.
  1698.  
  1699. You\&'ll have to get used to both \fBfit\fR and the kind of problems you apply it
  1700. to before you can relate the standard errors to some more practical estimates
  1701. of parameter uncertainties or evaluate the significance of the correlation
  1702. matrix.
  1703.  
  1704. Note that \fBfit\fR, in common with most NLLS implementations, minimizes the
  1705. weighted sum of squared distances (y-f(x))**2.  It does not provide any means
  1706. to account for "errors" in the values of x, only in y.  Also, any "outliers"
  1707. (data points outside the normal distribution of the model) will have an
  1708. exaggerated effect on the solution.
  1709. .sp 2
  1710. .RE
  1711. .br
  1712. .NH 2
  1713. Fit controlling
  1714. .sp 1
  1715. .LP
  1716. .XS
  1717. Fit controlling
  1718. .XE
  1719. There are a number of \fBgnuplot\fR variables that can be defined to affect
  1720. \fBfit\fR.  Those which can be defined once \fBgnuplot\fR is running are listed
  1721. under \&'control_variables\&' while those defined before starting \fBgnuplot\fR
  1722. are listed under \&'environment_variables\&'.
  1723. .sp 2
  1724. .RS
  1725. .IP
  1726. .NH 3
  1727. Control variables
  1728. .sp 1
  1729. .LP
  1730. .XS
  1731. Control variables
  1732. .XE
  1733. The default epsilon limit (1e-5) may be changed by declaring a value for
  1734. .br
  1735.       FIT_LIMIT
  1736. .br
  1737. When the sum of squared residuals changes between two iteration steps by
  1738. a factor less than this number (epsilon), the fit is considered to have
  1739. \&\&'converged\&'.
  1740.  
  1741. The maximum number of iterations may be limited by declaring a value for
  1742. .br
  1743.       FIT_MAXITER
  1744. .br
  1745. A value of 0 (or not defining it at all)  means that there is no limit.
  1746.  
  1747. If you need even more control about the algorithm, and know the
  1748. Marquardt-Levenberg algorithm well, there are some more variables to
  1749. influence it. The startup value of \fBlambda\fR is normally calculated
  1750. automatically from the ML-matrix, but if you want to, you may provide
  1751. your own one with
  1752. .br
  1753.       FIT_START_LAMBDA
  1754. .br
  1755. Specifying FIT_START_LAMBDA as zero or less will re-enable the automatic
  1756. selection. The variable
  1757. .br
  1758.       FIT_LAMBDA_FACTOR
  1759. .br
  1760. gives the factor by which \fBlambda\fR is increased or decreased whenever
  1761. the chi-squared target function increased or decreased significantly.
  1762. Setting FIT_LAMBDA_FACTOR to zero re-enables the default factor of
  1763. 10.0.
  1764.  
  1765. Oher variables with the FIT_ prefix may be added to \fBfit\fR, so it is safer
  1766. not to use that prefix for user-defined variables.
  1767.  
  1768. The variables FIT_SKIP and FIT_INDEX were used by earlier releases of
  1769. \fBgnuplot\fR with a \&'fit\&' patch called \fBgnufit\fR and are no longer available.
  1770. The datafile \fBevery\fR modifier provides the functionality of FIT_SKIP.
  1771. FIT_INDEX was used for multi-branch fitting, but multi-branch fitting of
  1772. one independent variable is now done as a pseudo-3D fit in which the
  1773. second independent variable and \fBusing\fR are used to specify the branch.
  1774. See \fBfit multi-branch\fR.
  1775. .sp 2
  1776. .NH 3
  1777. Environment variables
  1778. .sp 1
  1779. .LP
  1780. .XS
  1781. Environment variables
  1782. .XE
  1783. The environment variables must be defined before \fBgnuplot\fR is executed; how
  1784. to do so depends on your operating system.
  1785.  
  1786. .br
  1787.       FIT_LOG
  1788. .br
  1789. changes the name (and/or path) of the file to which the fit log will be
  1790. written from the default of "fit.log" in the working directory.
  1791.  
  1792. .br
  1793.       FIT_SCRIPT
  1794. .br
  1795. specifies a command that may be executed after an user interrupt. The default
  1796. is \fBreplot\fR, but a \fBplot\fR or \fBload\fR command may be useful to display a plot
  1797. customized to highlight the progress of the fit.
  1798. .sp 2
  1799. .RE
  1800. .br
  1801. .NH 2
  1802. Multi-branch
  1803. .sp 1
  1804. .LP
  1805. .XS
  1806. Multi-branch
  1807. .XE
  1808. In multi-branch fitting, multiple data sets can be simultaneously fit with
  1809. functions of one independent variable having common parameters by minimizing
  1810. the total WSSR.  The function and parameters (branch) for each data set are
  1811. selected by using a \&'pseudo-variable\&', e.g., either the dataline number (a
  1812. \&\&'column\&' index of -1) or the datafile index (-2), as the second independent
  1813. variable.
  1814.  
  1815. Example:  Given two exponential decays of the form, z=f(x), each describing
  1816. a different data set but having a common decay time, estimate the values of
  1817. the parameters.  If the datafile has the format x:z:s, then
  1818. .br
  1819.      f(x,y) = (y==0) ? a*exp(-x/tau) : b*exp(-x/tau)
  1820. .br
  1821. .br
  1822.      fit f(x,y) 'datafile' using  1:-1:2:3  via a, b, tau
  1823. .br
  1824.  
  1825. For a more complicated example, see the file "hexa.fnc" used by the
  1826. "fit.dem" demo.
  1827.  
  1828. Appropriate weighting may be required since unit weights may cause one
  1829. branch to predominate if there is a difference in the scale of the dependent
  1830. variable.  Fitting each branch separately, using the multi-branch solution
  1831. as initial values, may give an indication as to the relative effect of each
  1832. branch on the joint solution.
  1833. .sp 2
  1834. .NH 2
  1835. Starting values
  1836. .sp 1
  1837. .LP
  1838. .XS
  1839. Starting values
  1840. .XE
  1841. Nonlinear fitting is not guaranteed to converge to the global optimum (the
  1842. solution with the smallest sum of squared residuals, SSR), and can get stuck
  1843. at a local minimum.  The routine has no way to determine that;  it is up to
  1844. you to judge whether this has happened.
  1845.  
  1846. \fBfit\fR may, and often will get "lost" if started far from a solution, where
  1847. SSR is large and changing slowly as the parameters are varied, or it may
  1848. reach a numerically unstable region (e.g., too large a number causing a
  1849. floating point overflow) which results in an "undefined value" message
  1850. or \fBgnuplot\fR halting.
  1851.  
  1852. To improve the chances of finding the global optimum, you should set the
  1853. starting values at least roughly in the vicinity of the solution, e.g.,
  1854. within an order of magnitude, if possible.  The closer your starting values
  1855. are to the solution, the less chance of stopping at another minimum.  One way
  1856. to find starting values is to plot data and the fitting function on the same
  1857. graph and change parameter values and \fBreplot\fR until reasonable similarity
  1858. is reached.  The same plot is also useful to check whether the fit stopped at
  1859. a minimum with a poor fit.
  1860.  
  1861. Of course, a reasonably good fit is not proof there is not a "better" fit (in
  1862. either a statistical sense, characterized by an improved goodness-of-fit
  1863. criterion, or a physical sense, with a solution more consistent with the
  1864. model.)  Depending on the problem, it may be desirable to \fBfit\fR with various
  1865. sets of starting values, covering a reasonable range for each parameter.
  1866. .sp 2
  1867. .NH 2
  1868. Tips
  1869. .sp 1
  1870. .LP
  1871. .XS
  1872. Tips
  1873. .XE
  1874. Here are some tips to keep in mind to get the most out of \fBfit\fR.  They\&'re not
  1875. very organized, so you\&'ll have to read them several times until their essence
  1876. has sunk in.
  1877.  
  1878. The two forms of the \fBvia\fR argument to \fBfit\fR serve two largely distinct
  1879. purposes.  The \fBvia "file"\fR form is best used for (possibly unattended) batch
  1880. operation, where you just supply the startup values in a file and can later
  1881. use \fBupdate\fR to copy the results back into another (or the same) parameter
  1882. file.
  1883.  
  1884. The \fBvia var1, var2, ...\fR form is best used interactively, where the command
  1885. history mechanism may be used to edit the list of parameters to be fitted or
  1886. to supply new startup values for the next try.  This is particularly useful
  1887. for hard problems, where a direct fit to all parameters at once won\&'t work
  1888. without good starting values.  To find such, you can iterate several times,
  1889. fitting only some of the parameters, until the values are close enough to the
  1890. goal that the final fit to all parameters at once will work.
  1891.  
  1892. Make sure that there is no mutual dependency among parameters of the function
  1893. you are fitting.  For example, don\&'t try to fit a*exp(x+b), because
  1894. a*exp(x+b)=a*exp(b)*exp(x).  Instead, fit either a*exp(x) or exp(x+b).
  1895.  
  1896. A technical issue:  the parameters must not be too different in magnitude.
  1897. The larger the ratio of the largest and the smallest absolute parameter
  1898. values, the slower the fit will converge.  If the ratio is close to or above
  1899. the inverse of the machine floating point precision, it may take next to
  1900. forever to converge, or refuse to converge at all.  You will have to adapt
  1901. your function to avoid this, e.g., replace \&'parameter\&' by \&'1e9*parameter\&' in
  1902. the function definition, and divide the starting value by 1e9.
  1903.  
  1904. If you can write your function as a linear combination of simple functions
  1905. weighted by the parameters to be fitted, by all means do so.  That helps a
  1906. lot, because the problem is no longer nonlinear and should converge with only
  1907. a small number of iterations, perhaps just one.
  1908.  
  1909. Some prescriptions for analysing data, given in practical experimentation
  1910. courses, may have you first fit some functions to your data, perhaps in a
  1911. multi-step process of accounting for several aspects of the underlying
  1912. theory one by one, and then extract the information you really wanted from
  1913. the fitting parameters of those functions.  With \fBfit\fR, this may often be
  1914. done in one step by writing the model function directly in terms of the
  1915. desired parameters.  Transforming data can also quite often be avoided,
  1916. though sometimes at the cost of a more difficult fit problem.  If you think
  1917. this contradicts the previous paragraph about simplifying the fit function,
  1918. you are correct.
  1919.  
  1920. A "singular matrix" message indicates that this implementation of the
  1921. Marquardt-Levenberg algorithm can\&'t calculate parameter values for the next
  1922. iteration.  Try different starting values, writing the function in another
  1923. form, or a simpler function.
  1924.  
  1925. Finally, a nice quote from the manual of another fitting package (fudgit),
  1926. that kind of summarizes all these issues:  "Nonlinear fitting is an art!"
  1927. .sp 2
  1928. .RE
  1929. .br
  1930. .NH 1
  1931. Help
  1932. .sp 1
  1933. .LP
  1934. .XS
  1935. Help
  1936. .XE
  1937. The \fBhelp\fR command displays on-line help. To specify information on a
  1938. particular topic use the syntax:
  1939.  
  1940. .br
  1941.       help {<topic>}
  1942. .br
  1943.  
  1944. If <topic> is not specified, a short message is printed about \fBgnuplot\fR.
  1945. After help for the requested topic is given, a menu of subtopics is given;
  1946. help for a subtopic may be requested by typing its name, extending the help
  1947. request.  After that subtopic has been printed, the request may be extended
  1948. again or you may go back one level to the previous topic.  Eventually, the
  1949. \fBgnuplot\fR command line will return.
  1950.  
  1951. If a question mark (?) is given as the topic, the list of topics currently
  1952. available is printed on the screen.
  1953. .sp 2
  1954. .NH 1
  1955. If
  1956. .sp 1
  1957. .LP
  1958. .XS
  1959. If
  1960. .XE
  1961. The \fBif\fR command allows commands to be executed conditionally.
  1962.  
  1963. Syntax:
  1964. .br
  1965.       if (<condition>) <command-line>
  1966. .br
  1967.  
  1968. <condition> will be evaluated.  If it is true (non-zero), then the command(s)
  1969. of the <command-line> will be executed.  If <condition> is false (zero), then
  1970. the entire <command-line> is ignored.  Note that use of \fB;\fR to allow multiple
  1971. commands on the same line will _not_ end the conditionalized commands.
  1972.  
  1973. Examples:
  1974. .br
  1975.       pi=3
  1976. .br
  1977. .br
  1978.       if (pi!=acos(-1)) print "?Fixing pi!"; pi=acos(-1); print pi
  1979. .br
  1980. will display:
  1981. .br
  1982.       ?Fixing pi!
  1983. .br
  1984. .br
  1985.       3.14159265358979
  1986. .br
  1987. but
  1988. .br
  1989.       if (1==2) print "Never see this"; print "Or this either"
  1990. .br
  1991. will not display anything.
  1992.  
  1993. See \fBreread\fR for an example of how \fBif\fR and \fBreread\fR can be used together to
  1994. perform a loop.
  1995. .sp 2
  1996. .NH 1
  1997. Load
  1998. .sp 1
  1999. .LP
  2000. .XS
  2001. Load
  2002. .XE
  2003. The \fBload\fR command executes each line of the specified input file as if it
  2004. had been typed in interactively.  Files created by the \fBsave\fR command can
  2005. later be \fBload\fRed.  Any text file containing valid commands can be created
  2006. and then executed by the \fBload\fR command.  Files being \fBload\fRed may themselves
  2007. contain \fBload\fR or \fBcall\fR commands.  See \fBcomment\fR for information about
  2008. comments in commands.  To \fBload\fR with arguments, see \fBcall\fR.
  2009.  
  2010. The \fBload\fR command _must_ be the last command on a multi-command line.
  2011.  
  2012. Syntax:
  2013. .br
  2014.       load "<input-file>"
  2015. .br
  2016.  
  2017. The name of the input file must be enclosed in quotes.
  2018.  
  2019. The special filename "-" may be used to \fBload\fR commands from standard input.
  2020. This allows a \fBgnuplot\fR command file to accept some commands from standard
  2021. input.  Please see "help batch/interactive" for more details.
  2022.  
  2023. Examples:
  2024. .br
  2025.       load 'work.gnu'
  2026. .br
  2027. .br
  2028.       load "func.dat"
  2029. .br
  2030.  
  2031. The \fBload\fR command is performed implicitly on any file names given as
  2032. arguments to \fBgnuplot\fR.  These are loaded in the order specified, and
  2033. then \fBgnuplot\fR exits.
  2034. .sp 2
  2035. .NH 1
  2036. Pause
  2037. .sp 1
  2038. .LP
  2039. .XS
  2040. Pause
  2041. .XE
  2042. The \fBpause\fR command displays any text associated with the command and then
  2043. waits a specified amount of time or until the carriage return is pressed.
  2044. \fBpause\fR is especially useful in conjunction with \fBload\fR files.
  2045.  
  2046. Syntax:
  2047. .br
  2048.       pause <time> {"<string>"}
  2049. .br
  2050.  
  2051. <time> may be any integer constant or expression.  Choosing -1 will wait
  2052. until a carriage return is hit, zero (0) won\&'t pause at all, and a positive
  2053. integer will wait the specified number of seconds.  \fBpause 0\fR is synonymous
  2054. with \fBprint\fR.
  2055.  
  2056. Note: Since \fBpause\fR communicates with the operating system rather than the
  2057. graphics, it may behave differently with different device drivers (depending
  2058. upon how text and graphics are mixed).
  2059.  
  2060. Examples:
  2061. .br
  2062.       pause -1    # Wait until a carriage return is hit
  2063. .br
  2064. .br
  2065.       pause 3     # Wait three seconds
  2066. .br
  2067. .br
  2068.       pause -1  "Hit return to continue"
  2069. .br
  2070. .br
  2071.       pause 10  "Isn't this pretty?  It's a cubic spline."
  2072. .br
  2073.  
  2074. .sp 2
  2075. .NH 1
  2076. Plot
  2077. .sp 1
  2078. .LP
  2079. .XS
  2080. Plot
  2081. .XE
  2082. \fBplot\fR is the primary command for drawing plots with \fBgnuplot\fR.  It creates
  2083. plots of functions and data in many, many ways.  \fBplot\fR is used to draw 2-d
  2084. functions and data; \fBsplot\fR draws 2-d projections of 3-d surfaces and data.
  2085. \fBplot\fR and \fBsplot\fR contain many common features; see \fBsplot\fR for differences.
  2086. Note specifically that \fBsplot\fR\&'s \fBbinary\fR and \fBmatrix\fR options do not exist
  2087. for \fBplot\fR.
  2088.  
  2089. Syntax:
  2090. .br
  2091.       plot {<ranges>}
  2092. .br
  2093. .br
  2094.            {<function> | {"<datafile>" {datafile-modifiers}}}
  2095. .br
  2096. .br
  2097.            {axes <axes>} {<title-spec>} {with <style>}
  2098. .br
  2099. .br
  2100.            {, {definitions,} <function> ...}
  2101. .br
  2102.  
  2103. where either a <function> or the name of a data file enclosed in quotes is
  2104. supplied.  A function is a mathematical expression or a pair of mathematical
  2105. expressions in parametric mode.  The expressions may be defined completely or
  2106. in part earlier in the stream of \fBgnuplot\fR commands (see \fBuser-defined\fR).
  2107.  
  2108. It is also possible to define functions and parameters on the \fBplot\fR command
  2109. itself.  This is done merely by isolating them from other items with commas.
  2110.  
  2111. There are four possible sets of axes available; the keyword <axes> is used to
  2112. select the axes for which a particular line should be scaled.  \fBx1y1\fR refers
  2113. to the axes on the bottom and left; \fBx2y2\fR to those on the top and right;
  2114. \fBx1y2\fR to those on the bottom and right; and \fBx2y1\fR to those on the top and
  2115. left.  Ranges specified on the \fBplot\fR command apply only to the first set of
  2116. axes (bottom left).
  2117.  
  2118. Examples:
  2119. .br
  2120.       plot sin(x)
  2121. .br
  2122. .br
  2123.       plot f(x) = sin(x*a), a = .2, f(x), a = .4, f(x)
  2124. .br
  2125. .br
  2126.       plot [t=1:10] [-pi:pi*2] tan(t), \\
  2127. .br
  2128. .br
  2129.            "data.1" using (tan($2)):($3/$4) smooth csplines \\
  2130. .br
  2131. .br
  2132.                     axes x1y2 notitle with lines 5
  2133. .br
  2134.  
  2135. .sp 2
  2136. .RS
  2137. .IP
  2138. .NH 2
  2139. Data-file
  2140. .sp 1
  2141. .LP
  2142. .XS
  2143. Data-file
  2144. .XE
  2145. Discrete data contained in a file can be displayed by specifying the name of
  2146. the data file (enclosed in single or double quotes) on the \fBplot\fR command line.
  2147.  
  2148. Syntax:
  2149. .br
  2150.       plot '<file_name>' {index <index list>}
  2151. .br
  2152. .br
  2153.                             {every <every list>}
  2154. .br
  2155. .br
  2156.                             {thru <thru expression>}
  2157. .br
  2158. .br
  2159.                             {using <using list>}
  2160. .br
  2161. .br
  2162.                             {smooth <option>}
  2163. .br
  2164.  
  2165. The modifiers \fBindex\fR, \fBevery\fR, \fBthru\fR, \fBusing\fR, and \fBsmooth\fR are discussed
  2166. separately.  In brief, \fBindex\fR selects which data sets in a multi-data-set
  2167. file are to be plotted, \fBevery\fR specifies which points within a single data
  2168. set are to be plotted, \fBusing\fR determines how the columns within a single
  2169. record are to be interpreted (\fBthru\fR is a special case of \fBusing\fR), and
  2170. \fBsmooth\fR allows for simple interpolation and approximation.  (\&'splot\&' has a
  2171. similar syntax, but does not support the \fBsmooth\fR and \fBthru\fR options.)
  2172.  
  2173. Data files should contain at least one data point per record (\fBusing\fR can
  2174. select one data point from the record).  Records beginning with \fB#\fR (and
  2175. also with \fB!\fR on VMS) will be treated as comments and ignored.  Each data
  2176. point represents an (x,y) pair.  For \fBplot\fRs with error bars (see \fBset style
  2177. errorbars\fR), each data point is (x,y,ydelta), (x,y,ylow,yhigh), (x,y,xdelta),
  2178. (x,y,xlow,xhigh), or (x,y,xlow,xhigh,ylow,yhigh).  In all cases, the numbers
  2179. on each record of a data file must be separated by white space (one or more
  2180. blanks or tabs), unless a format specifier is provided by the \fBusing\fR option.
  2181. This white space divides each record into columns.
  2182.  
  2183. Data may be written in exponential format with the exponent preceded by the
  2184. letter e, E, d, D, q, or Q.
  2185.  
  2186. Only one column (the y value) need be provided.  If x is omitted, \fBgnuplot\fR
  2187. provides integer values starting at 0.
  2188.  
  2189. In datafiles, blank records (records with no characters other than blanks and
  2190. a newline and/or carriage return) are significant---pairs of blank records
  2191. separate \fBindex\fRes (see \fBplot datafile index\fR).  Data separated by double
  2192. blank records are treated as if they were in separate data files.
  2193.  
  2194. Single blank records designate discontinuities in a \fBplot\fR; no line will join
  2195. points separated by a blank records (if they are plotted with a line style).
  2196.  
  2197. If autoscaling has been enabled (\fBset autoscale\fR), the axes are automatically
  2198. extended to include all datapoints, with a whole number of tic marks if tics
  2199. are being drawn.  This has two consequences: i) For \fBsplot\fR, the corner of
  2200. the surface may not coincide with the corner of the base.  In this case, no
  2201. vertical line is drawn.  ii) When plotting data with the same x range on a
  2202. dual-axis graph, the x coordinates may not coincide if the x2tics are not
  2203. being drawn.  This is because the x axis has been autoextended to a whole
  2204. number of tics, but the x2 axis has not.  The following example illustrates
  2205. the problem:
  2206.  
  2207. .br
  2208.       reset; plot '-', '-'
  2209. .br
  2210. .br
  2211.       1 1
  2212. .br
  2213. .br
  2214.       19 19
  2215. .br
  2216. .br
  2217.       e
  2218. .br
  2219. .br
  2220.       1 1
  2221. .br
  2222. .br
  2223.       19 19
  2224. .br
  2225. .br
  2226.       e
  2227. .br
  2228. .sp 2
  2229. .RS
  2230. .IP
  2231. .NH 3
  2232. Every
  2233. .sp 1
  2234. .LP
  2235. .XS
  2236. Every
  2237. .XE
  2238. The \fBevery\fR keyword allows a periodic sampling of a data set to be plotted.
  2239.  
  2240. In the discussion a "point" is a datum defined by a single record in the
  2241. file; "block" here will mean the same thing as "datablock" (see \fBglossary\fR).
  2242.  
  2243. Syntax:
  2244. .br
  2245.       plot 'file' every {<point_incr>}
  2246. .br
  2247. .br
  2248.                           {:{<block_incr>}
  2249. .br
  2250. .br
  2251.                             {:{<start_point>}
  2252. .br
  2253. .br
  2254.                               {:{<start_block>}
  2255. .br
  2256. .br
  2257.                                 {:{<end_point>}
  2258. .br
  2259. .br
  2260.                                   {:<end_block>}}}}}
  2261. .br
  2262.  
  2263. The data points to be plotted are selected according to a loop from
  2264. <\fBstart_point\fR> to <\fBend_point\fR> with increment <\fBpoint_incr\fR> and the
  2265. blocks according to a loop from <\fBstart_block\fR> to <\fBend_block\fR> with
  2266. increment <\fBblock_incr\fR>.
  2267.  
  2268. The first datum in each block is numbered \&'0\&', as is the first block in the
  2269. file.
  2270.  
  2271. Note that records containing unplottable information are counted.
  2272.  
  2273. Any of the numbers can be omitted; the increments default to unity, the start
  2274. values to the first point or block, and the end values to the last point or
  2275. block.  If \fBevery\fR is not specified, all points in all lines are plotted.
  2276.  
  2277. Examples:
  2278. .br
  2279.       every :::3::3    # selects just the fourth block ('0' is first)
  2280. .br
  2281. .br
  2282.       every :::::9     # selects the first 10 blocks
  2283. .br
  2284. .br
  2285.       every 2:2        # selects every other point in every other block
  2286. .br
  2287. .br
  2288.       every ::5::15    # selects points 5 through 15 in each block
  2289. .br
  2290. .sp 2
  2291. .NH 3
  2292. Example datafile
  2293. .sp 1
  2294. .LP
  2295. .XS
  2296. Example datafile
  2297. .XE
  2298. This example plots the data in the file "population.dat" and a theoretical
  2299. curve:
  2300.  
  2301. .br
  2302.       pop(x) = 103*exp((1965-x)/10)
  2303. .br
  2304. .br
  2305.       plot [1960:1990] 'population.dat', pop(x)
  2306. .br
  2307.  
  2308. The file "population.dat" might contain:
  2309.  
  2310. .br
  2311.       # Gnu population in Antarctica since 1965
  2312. .br
  2313. .br
  2314.          1965   103
  2315. .br
  2316. .br
  2317.          1970   55
  2318. .br
  2319. .br
  2320.          1975   34
  2321. .br
  2322. .br
  2323.          1980   24
  2324. .br
  2325. .br
  2326.          1985   10
  2327. .br
  2328.  
  2329. .sp 2
  2330. .NH 3
  2331. Index
  2332. .sp 1
  2333. .LP
  2334. .XS
  2335. Index
  2336. .XE
  2337. The \fBindex\fR keyword allows only some of the data sets in a multi-data-set
  2338. file to be plotted.
  2339.  
  2340. Syntax:
  2341. .br
  2342.       plot 'file' index <m>{{:<n>}:<p>}
  2343. .br
  2344.  
  2345. Data sets are separated by pairs of blank records.  \fBindex <m>\fR selects only
  2346. set <m>; \fBindex <m>:<n>\fR selects sets in the range <m> to <n>; and \fBindex
  2347. <m>:<n>:<p>\fR selects indices <m>, <m>+<p>, <m>+2<p>, etc., but stopping at
  2348. <n>.  Following C indexing, the index 0 is assigned to the first data set in
  2349. the file.  Specifying too large an index results in an error message.  If
  2350. \fBindex\fR is not specified, all sets are plotted as a single data set.
  2351.  
  2352. Example:
  2353. .br
  2354.       plot 'file' index 4:5
  2355. .br
  2356. .sp 2
  2357. .NH 3
  2358. Smooth
  2359. .sp 1
  2360. .LP
  2361. .XS
  2362. Smooth
  2363. .XE
  2364. \fBgnuplot\fR includes a few general-purpose routines for interpolation and
  2365. approximation of data; these are grouped under the \fBsmooth\fR option.  More
  2366. sophisticated data processing may be performed by preprocessing the data
  2367. externally or by using \fBfit\fR with an appropriate model.
  2368.  
  2369. Syntax:
  2370. .br
  2371.       smooth {unique | csplines | acsplines | bezier | sbezier}
  2372. .br
  2373.  
  2374. \fBunique\fR plots the data after making them monotonic.  Each of the other
  2375. routines uses the data to determine the coefficients of a continuous curve
  2376. between the endpoints of the data.  This curve is then plotted in the same
  2377. manner as a function, that is, by finding its value at uniform intervals
  2378. along the abscissa (see \fBset samples\fR) and connecting these points with
  2379. straight line segments (if a line style is chosen).
  2380.  
  2381. If \fBautoscale\fR is in effect, the ranges will be computed such that the
  2382. plotted curve lies within the borders of the graph.
  2383.  
  2384. If too few points are available to allow the selected option to be applied,
  2385. an error message is produced.  The minimum number is one for \fBunique\fR, four
  2386. for \fBacsplines\fR, and three for the others.
  2387.  
  2388. The \fBsmooth\fR options have no effect on function plots.
  2389. .sp 2
  2390. .RS
  2391. .IP
  2392. .NH 4
  2393. Acsplines
  2394. .sp 1
  2395. .LP
  2396. .XS
  2397. Acsplines
  2398. .XE
  2399. The \fBacsplines\fR option approximates the data with a "natural smoothing spline".
  2400. After the data are made monotonic in x (see \fBsmooth unique\fR), a curve is
  2401. piecewise constructed from segments of cubic polynomials whose coefficients
  2402. are found by the weighting the data points; the weights are taken from the
  2403. third column in the data file.  That default can be modified by the third
  2404. entry in the \fBusing\fR list, e.g.,
  2405. .br
  2406.       plot 'data-file' using 1:2:(1.0) smooth acsplines
  2407. .br
  2408.  
  2409. Qualitatively, the absolute magnitude of the weights determines the number
  2410. of segments used to construct the curve.  If the weights are large, the
  2411. effect of each datum is large and the curve approaches that produced by
  2412. connecting consecutive points with natural cubic splines.  If the weights are
  2413. small, the curve is composed of fewer segments and thus is smoother; the
  2414. limiting case is the single segment produced by a weighted linear least
  2415. squares fit to all the data.  The smoothing weight can be expressed in terms
  2416. of errors as a statistical weight for a point divided by a "smoothing factor"
  2417. for the curve so that (standard) errors in the file can be used as smoothing
  2418. weights.
  2419.  
  2420. Example:
  2421. .br
  2422.       sw(x,S)=1/(x*x*S)
  2423. .br
  2424. .br
  2425.       plot 'data_file' using 1:2:(sw($3,100)) smooth acsplines
  2426. .br
  2427. .sp 2
  2428. .NH 4
  2429. Bezier
  2430. .sp 1
  2431. .LP
  2432. .XS
  2433. Bezier
  2434. .XE
  2435. The \fBbezier\fR option approximates the data with a Bezier curve of degree n
  2436. (the number of data points) that connects the endpoints.
  2437. .sp 2
  2438. .NH 4
  2439. Csplines
  2440. .sp 1
  2441. .LP
  2442. .XS
  2443. Csplines
  2444. .XE
  2445. The \fBcsplines\fR option connects consecutive points by natural cubic splines
  2446. after rendering the data monotonic (see \fBsmooth unique\fR).
  2447. .sp 2
  2448. .NH 4
  2449. Sbezier
  2450. .sp 1
  2451. .LP
  2452. .XS
  2453. Sbezier
  2454. .XE
  2455. The \fBsbezier\fR option first renders the data monotonic (\fBunique\fR) and then
  2456. applies the \fBbezier\fR algorithm.
  2457. .sp 2
  2458. .NH 4
  2459. Unique
  2460. .sp 1
  2461. .LP
  2462. .XS
  2463. Unique
  2464. .XE
  2465. The \fBunique\fR option makes the data monotonic in x; points with the same
  2466. x-value are replaced by a single point having the average y-value.  The
  2467. resulting points are then connected by straight line segments.
  2468. .sp 2
  2469. .RE
  2470. .br
  2471. .NH 3
  2472. Special-filenames
  2473. .sp 1
  2474. .LP
  2475. .XS
  2476. Special-filenames
  2477. .XE
  2478. A special filename of \fB\&'-\&'\fR specifies that the data are inline; i.e., they
  2479. follow the command.  Only the data follow the command; \fBplot\fR options like
  2480. filters, titles, and line styles remain on the \&'plot\&' command line.  This is
  2481. similar to << in unix shell script, and $DECK in VMS DCL.  The data are
  2482. entered as though they are being read from a file, one data point per record.
  2483. The letter "e" at the start of the first column terminates data entry.  The
  2484. \fBusing\fR option can be applied to these data---using it to filter them through
  2485. a function might make sense, but selecting columns probably doesn\&'t!
  2486.  
  2487. \fB\&'-\&'\fR is intended for situations where it is useful to have data and commands
  2488. together, e.g., when \fBgnuplot\fR is run as a sub-process of some front-end
  2489. application.  Some of the demos, for example, might use this feature.  While
  2490. \fBplot\fR options such as \fBindex\fR and \fBevery\fR are recognized, their use forces
  2491. you to enter data that won\&'t be used.  For example, while
  2492.  
  2493. .br
  2494.       plot '-' index 0, '-' index 1
  2495. .br
  2496. .br
  2497.       2
  2498. .br
  2499. .br
  2500.       4
  2501. .br
  2502. .br
  2503.       6
  2504. .br
  2505.  
  2506.  
  2507. .br
  2508.       10
  2509. .br
  2510. .br
  2511.       12
  2512. .br
  2513. .br
  2514.       14
  2515. .br
  2516. .br
  2517.       e
  2518. .br
  2519. .br
  2520.       2
  2521. .br
  2522. .br
  2523.       4
  2524. .br
  2525. .br
  2526.       6
  2527. .br
  2528.  
  2529.  
  2530. .br
  2531.       10
  2532. .br
  2533. .br
  2534.       12
  2535. .br
  2536. .br
  2537.       14
  2538. .br
  2539. .br
  2540.       e
  2541. .br
  2542.  
  2543. does indeed work,
  2544.  
  2545. .br
  2546.       plot '-', '-'
  2547. .br
  2548. .br
  2549.       2
  2550. .br
  2551. .br
  2552.       4
  2553. .br
  2554. .br
  2555.       6
  2556. .br
  2557. .br
  2558.       e
  2559. .br
  2560. .br
  2561.       10
  2562. .br
  2563. .br
  2564.       12
  2565. .br
  2566. .br
  2567.       14
  2568. .br
  2569. .br
  2570.       e
  2571. .br
  2572.  
  2573. is a lot easier to type.
  2574.  
  2575. If you use \fB\&'-\&'\fR with \fBreplot\fR, you may need to enter the data more than once
  2576. (see \fBreplot\fR).
  2577.  
  2578. A blank filename (\&'\&') specifies that the previous filename should be reused.
  2579. This can be useful with things like
  2580.  
  2581. .br
  2582.       plot 'a/very/long/filename' using 1:2, '' using 1:3, '' using 1:4
  2583. .br
  2584.  
  2585. (If you use both \fB\&'-\&'\fR and \fB\&'\&'\fR on the same \fBplot\fR command, you\&'ll need to
  2586. have two sets of inline data, as in the example above.)
  2587.  
  2588. On some computer systems with a popen function (Unix), the datafile can be
  2589. piped through a shell command by starting the file name with a \&'<\&'.  For
  2590. example,
  2591.  
  2592. .br
  2593.       pop(x) = 103*exp(-x/10)
  2594. .br
  2595. .br
  2596.       plot "< awk '{print $1-1965, $2}' population.dat", pop(x)
  2597. .br
  2598.  
  2599. would plot the same information as the first population example but with
  2600. years since 1965 as the x axis.  If you want to execute this example, you
  2601. have to delete all comments from the data file above or substitute the
  2602. following command for the first part of the command above (the part up to
  2603. the comma):
  2604.  
  2605. .br
  2606.       plot "< awk '$0 !~ /^#/ {print $1-1965, $2}' population.dat"
  2607. .br
  2608.  
  2609. While this approach is most flexible, it is possible to achieve simple
  2610. filtering with the \fBusing\fR or \fBthru\fR keywords.
  2611. .sp 2
  2612. .NH 3
  2613. Thru
  2614. .sp 1
  2615. .LP
  2616. .XS
  2617. Thru
  2618. .XE
  2619. The \fBthru\fR function is provided for backward compatibility.
  2620.  
  2621. Syntax:
  2622. .br
  2623.       plot 'file' thru f(x)
  2624. .br
  2625.  
  2626. It is equivalent to:
  2627.  
  2628. .br
  2629.       plot 'file' using 1:(f($2))
  2630. .br
  2631.  
  2632. While the latter appears more complex, it is much more flexible.  The more
  2633. natural
  2634.  
  2635. .br
  2636.       plot 'file' thru f(y)
  2637. .br
  2638.  
  2639. also works (i.e. you can use y as the dummy variable).
  2640.  
  2641. \fBthru\fR is parsed for \fBsplot\fR and \fBfit\fR but has no effect.
  2642. .sp 2
  2643. .NH 3
  2644. Using
  2645. .sp 1
  2646. .LP
  2647. .XS
  2648. Using
  2649. .XE
  2650. The most common datafile modifier is \fBusing\fR.
  2651.  
  2652. Syntax:
  2653. .br
  2654.       plot 'file' using {<entry> {:<entry> {:<entry> ...}}} {'format'}
  2655. .br
  2656.  
  2657. If a format is specified, each datafile record is read using the C library\&'s
  2658. \&\&'scanf\&' function, with the specified format string.  Otherwise the record is
  2659. read and broken into columns at spaces or tabs.  A format cannot be specified
  2660. if time-format data is being used (this must be done by \fBset data time\fR).
  2661.  
  2662. The resulting array of data is then sorted into columns according to the
  2663. entries.  Each <entry> may be a simple column number, which selects the
  2664. datum, an expression enclosed in parentheses, or empty.  The expression can
  2665. use $1 to access the first item read, $2 for the second item, and so on.  It
  2666. can also use \fBcolumn(x)\fR and \fBvalid(x)\fR where x is an arbitrary expression
  2667. resulting in an integer.  \fBcolumn(x)\fR returns the x\&'th datum; \fBvalid(x)\fR
  2668. tests that the datum in the x\&'th column is a valid number.  A column number
  2669. of 0 generates a number increasing (from zero) with each point, and is reset
  2670. upon encountering two blank records.  A column number of -1 gives the
  2671. dataline number, which starts at 0, increments at single blank records, and
  2672. is reset at double blank records.  A column number of -2 gives the index
  2673. number, which is incremented only when two blank records are found.  An empty
  2674. <entry> will default to its order in the list of entries.  For example,
  2675. \fBusing ::4\fR is interpreted as \fBusing 1:2:4\fR.
  2676.  
  2677. N.B.---the \fBcall\fR command also uses $\&'s as a special character.  See \fBcall\fR
  2678. for details about how to include a column number in a \fBcall\fR argument list.
  2679.  
  2680. If the \fBusing\fR list has but a single entry, that <entry> will be used for y
  2681. and the data point number is used for x; for example, "\fBplot \&'file\&' using 1\fR"
  2682. is identical to "\fBplot \&'file\&' using 0:1\fR".  If the \fBusing\fR list has two
  2683. entries, these will be used for x and y.  Additional entries are usually
  2684. errors in x and/or y.  See \fBset style\fR for details about plotting styles that
  2685. make use of error information, and \fBfit\fR for use of error information in
  2686. curve fitting.
  2687.  
  2688. \&\&'scanf\&' accepts several numerical specifications but \fBgnuplot\fR requires all
  2689. inputs to be double-precision floating-point variables, so \fBlf\fR is the only
  2690. permissible specifier.  \&'scanf\&' expects to see white space---a blank, tab
  2691. ("\\t"), newline ("\\n"), or formfeed ("\\f")---between numbers; anything else
  2692. in the input stream must be explicitly skipped.
  2693.  
  2694. Note that the use of "\\t", "\\n", or "\\f" or requires use of double-quotes
  2695. rather than single-quotes.
  2696.  
  2697. Examples:
  2698.  
  2699. This creates a plot of the sum of the 2nd and 3rd data against the first:
  2700. (The format string specifies comma- rather than space-separated columns.)
  2701. .br
  2702.       plot 'file' using 1:($2+$3) '%lf,%lf,%lf'
  2703. .br
  2704.  
  2705. In this example the data are read from the file "MyData" using a more
  2706. complicated format:
  2707. .br
  2708.       plot 'MyData' using "%*lf%lf%*20[^\\n]%lf"
  2709. .br
  2710.  
  2711. The meaning of this format is:
  2712.  
  2713. .br
  2714.       %*lf        ignore a number
  2715. .br
  2716. .br
  2717.       %lf         read a double-precision number (x by default)
  2718. .br
  2719. .br
  2720.       %*20[^\\n]   ignore 20 non-newline characters
  2721. .br
  2722. .br
  2723.       %lf         read a double-precision number (y by default)
  2724. .br
  2725.  
  2726. One trick is to use the ternary \fB?:\fR operator to filter data:
  2727.  
  2728. .br
  2729.       plot 'file' using 1:($3>10 ? $2 : 1/0)
  2730. .br
  2731.  
  2732. which plots the datum in column two against that in column one provided
  2733. the datum in column three exceeds ten.  \fB1/0\fR is undefined; \fBgnuplot\fR
  2734. quietly ignores undefined points, so unsuitable points are suppressed.
  2735.  
  2736. In fact, you can use a constant expression for the column number, provided it
  2737. doesn\&'t start with an opening parenthesis; constructs like \fBusing
  2738. 0+(complicated expression)\fR can be used.  The crucial point is that the
  2739. expression is evaluated once if it doesn\&'t start with a left parenthesis, or
  2740. once for each data point read if it does.
  2741.  
  2742. If timeseries data are being used, the time can span multiple columns.  The
  2743. starting column should be specified.  Note that the spaces within the time
  2744. must be included when calculating starting columns for other data.  E.g., if
  2745. the first element on a line is a time with an embedded space, the y value
  2746. should be specified as column three.
  2747.  
  2748. It should be noted that \fBplot \&'file\&'\fR, \fBplot \&'file\&' using 1:2\fR, and \fBplot
  2749. \&\&'file\&' using ($1):($2)\fR can be subtly different: 1) if \fBfile\fR has some lines
  2750. with one column and some with two, the first will invent x values when they
  2751. are missing, the second will quietly ignore the lines with one column, and
  2752. the third will store an undefined value for lines with one point (so that in
  2753. a plot with lines, no line joins points across the bad point); 2) if a line
  2754. contains text at the first column, the first will abort the plot on an error,
  2755. but the second and third should quietly skip the garbage.
  2756.  
  2757. In fact, it is often possible to plot a file with lots of lines of garbage at
  2758. the top simply by specifying
  2759.  
  2760. .br
  2761.       plot 'file' using 1:2
  2762. .br
  2763.  
  2764. However, if you want to leave text in your data files, it is safer to put the
  2765. comment character (#) in the first column of the text lines.
  2766. .sp 2
  2767. .RE
  2768. .br
  2769. .NH 2
  2770. Errorbars
  2771. .sp 1
  2772. .LP
  2773. .XS
  2774. Errorbars
  2775. .XE
  2776. Error bars are supported for 2-d data file plots by reading one to four
  2777. additional columns (or \fBusing\fR entries); these additional values are used in
  2778. different ways by the various errorbar styles.
  2779.  
  2780. In the default situation, \fBgnuplot\fR expects to see three, four, or six
  2781. numbers on each line of the data file---either
  2782.  
  2783. .br
  2784.       (x, y, ydelta),
  2785. .br
  2786. .br
  2787.       (x, y, ylow, yhigh),
  2788. .br
  2789. .br
  2790.       (x, y, xdelta),
  2791. .br
  2792. .br
  2793.       (x, y, xlow, xhigh),
  2794. .br
  2795. .br
  2796.       (x, y, xdelta, ydelta), or
  2797. .br
  2798. .br
  2799.       (x, y, xlow, xhigh, ylow, yhigh).
  2800. .br
  2801.  
  2802. The x coordinate must be specified.  The order of the numbers must be
  2803. exactly as given above, though the \fBusing\fR qualifier can manipulate the order
  2804. and provide values for missing columns.  For example,
  2805.  
  2806. .br
  2807.       plot 'file' with errorbars
  2808. .br
  2809. .br
  2810.       plot 'file' using 1:2:(sqrt($1)) with xerrorbars
  2811. .br
  2812. .br
  2813.       plot 'file' using 1:2:($1-$3):($1+$3):4:5 with xyerrorbars
  2814. .br
  2815.  
  2816. The last example is for a file containing an unsupported combination of
  2817. relative x and absolute y errors.  The \fBusing\fR entry generates absolute x min
  2818. and max from the relative error.
  2819.  
  2820. The y error bar is a vertical line plotted from (x, ylow) to (x, yhigh).
  2821. If ydelta is specified instead of ylow and yhigh, ylow = y - ydelta and
  2822. yhigh = y + ydelta are derived.  If there are only two numbers on the record,
  2823. yhigh and ylow are both set to y.  The x error bar is a horizontal line
  2824. computed in the same fashion.  To get lines plotted between the data points,
  2825. \fBplot\fR the data file twice, once with errorbars and once with lines (but
  2826. remember to use the \fBnotitle\fR option on one to avoid two entries in the key).
  2827.  
  2828. The error bars have crossbars at each end unless \fBset bar\fR is used (see \fBset
  2829. bar\fR for details).
  2830.  
  2831. If autoscaling is on, the ranges will be adjusted to include the error bars.
  2832.  
  2833. See \fBplot using\fR, \fBplot with\fR, and \fBset style\fR for more information.
  2834. .sp 2
  2835. .NH 2
  2836. Parametric
  2837. .sp 1
  2838. .LP
  2839. .XS
  2840. Parametric
  2841. .XE
  2842. When in parametric mode (\fBset parametric\fR) mathematical expressions must be
  2843. given in pairs for \fBplot\fR and in triplets for \fBsplot\fR.
  2844.  
  2845. Examples:
  2846. .br
  2847.       plot sin(t),t**2
  2848. .br
  2849. .br
  2850.       splot cos(u)*cos(v),cos(u)*sin(v),sin(u)
  2851. .br
  2852.  
  2853. Data files are plotted as before, except any preceding parametric function
  2854. must be fully specified before a data file is given as a plot.  In other
  2855. words, the x parametric function (\fBsin(t)\fR above) and the y parametric
  2856. function (\fBt**2\fR above) must not be interrupted with any modifiers or data
  2857. functions; doing so will generate a syntax error stating that the parametric
  2858. function is not fully specified.
  2859.  
  2860. Other modifiers, such as \fBwith\fR and \fBtitle\fR, may be specified only after the
  2861. parametric function has been completed:
  2862.  
  2863. .br
  2864.       plot sin(t),t**2 title 'Parametric example' with linespoints
  2865. .br
  2866. .sp 2
  2867. .NH 2
  2868. Ranges
  2869. .sp 1
  2870. .LP
  2871. .XS
  2872. Ranges
  2873. .XE
  2874. The optional ranges specify the region of the graph that will be displayed.
  2875.  
  2876. Syntax:
  2877. .br
  2878.       [{<dummy-var>=}{{<min>}:{<max>}}]
  2879. .br
  2880. .br
  2881.       [{{<min>}:{<max>}}]
  2882. .br
  2883.  
  2884. The first form applies to the independent variable (\fBxrange\fR or \fBtrange\fR, if
  2885. in parametric mode).  The second form applies to the dependent variable
  2886. \fByrange\fR (and \fBxrange\fR, too, if in parametric mode).  <dummy-var> is a new
  2887. name for the independent variable.  (The defaults may be changed with \fBset
  2888. dummy\fR.)  The optional <min> and <max> terms can be constant expressions or *.
  2889.  
  2890. In non-parametric mode, the order in which ranges must be given is \fBxrange\fR
  2891. and \fByrange\fR.
  2892.  
  2893. In parametric mode, the order for the \fBplot\fR command is \fBtrange\fR, \fBxrange\fR,
  2894. and \fByrange\fR.  The following \fBplot\fR command shows setting the \fBtrange\fR to
  2895. [-pi:pi], the \fBxrange\fR to [-1.3:1.3] and the \fByrange\fR to [-1:1] for the
  2896. duration of the graph:
  2897.  
  2898. .br
  2899.       plot [-pi:pi] [-1.3:1.3] [-1:1] sin(t),t**2
  2900. .br
  2901.  
  2902. Note that the x2range and y2range cannot be specified here---\fBset x2range\fR
  2903. and \fBset y2range\fR must be used.
  2904.  
  2905. Ranges are interpreted in the order listed above for the appropriate mode.
  2906. Once all those needed are specified, no further ones must be listed, but
  2907. unneeded ones cannot be skipped---use an empty range \fB[]\fR as a placeholder.
  2908.  
  2909. \fB*\fR can be used to allow autoscaling of either of min and max.  See also
  2910. \fBset autoscale\fR.
  2911.  
  2912. Ranges specified on the \fBplot\fR or \fBsplot\fR command line affect only that
  2913. graph; use the \fBset xrange\fR, \fBset yrange\fR, etc., commands to change the
  2914. default ranges for future graphs.
  2915.  
  2916. With time data, you must provide the range (in the same manner as the time
  2917. appears in the datafile) within quotes.  \fBgnuplot\fR uses the \fBtimefmt\fR string
  2918. to read the value---see \fBset timefmt\fR.
  2919.  
  2920. Examples:
  2921.  
  2922. This uses the current ranges:
  2923. .br
  2924.       plot cos(x)
  2925. .br
  2926.  
  2927. This sets the x range only:
  2928. .br
  2929.       plot [-10:30] sin(pi*x)/(pi*x)
  2930. .br
  2931.  
  2932. This is the same, but uses t as the dummy-variable:
  2933. .br
  2934.       plot [t = -10 :30]  sin(pi*t)/(pi*t)
  2935. .br
  2936.  
  2937. This sets both the x and y ranges:
  2938. .br
  2939.       plot [-pi:pi] [-3:3]  tan(x), 1/x
  2940. .br
  2941.  
  2942. This sets only the y range, and turns off autoscaling on both axes:
  2943. .br
  2944.       plot [ ] [-2:sin(5)*-8] sin(x)**besj0(x)
  2945. .br
  2946.  
  2947. This sets xmax and ymin only:
  2948. .br
  2949.       plot [:200] [-pi:]  exp(sin(x))
  2950. .br
  2951.  
  2952. This sets the x range for a timeseries:
  2953. .br
  2954.       set timefmt "%d/%m/%y %H:%M"
  2955. .br
  2956. .br
  2957.       plot ["1/6/93 12:00":"5/6/93 12:00"] 'timedata.dat'
  2958. .br
  2959.  
  2960. .sp 2
  2961. .NH 2
  2962. Title
  2963. .sp 1
  2964. .LP
  2965. .XS
  2966. Title
  2967. .XE
  2968. A line title for each function and data set appears in the key, accompanied
  2969. by a sample of the line and/or symbol used to represent it.  It can be
  2970. changed by using the \fBtitle\fR option.
  2971.  
  2972. Syntax:
  2973. .br
  2974.       title "<title>" | notitle
  2975. .br
  2976.  
  2977. where <title> is the new title of the line and must be enclosed in quotes.
  2978. The quotes will not be shown in the key.  A special character may be given as
  2979. a backslash followed by its octal value ("\\345").  The tab character "\\t" is
  2980. understood.  Note that backslash processing occurs only for strings enclosed
  2981. in double quotes---use single quotes to prevent such processing.  The newline
  2982. character "\\n" is not processed in key entries in either type of string.
  2983.  
  2984. The line title and sample can be omitted from the key by using the keyword
  2985. \fBnotitle\fR.  A null title (\fBtitle \&'\&'\fR) is equivalent to \fBnotitle\fR.  If only
  2986. the sample is wanted, use one or more blanks (\fBtitle \&' \&'\fR).
  2987.  
  2988. By default the line title is the function or file name as it appears on the
  2989. \fBplot\fR command.  If it is a file name, any datafile modifiers specified will
  2990. be included in the default title.
  2991.  
  2992. The layout of the key itself (position, title justification, etc.) can be
  2993. controlled by \fBset key\fR.  Please see \fBset key\fR for details.
  2994.  
  2995. Examples:
  2996.  
  2997. This plots y=x with the title \&'x\&':
  2998. .br
  2999.       plot x
  3000. .br
  3001.  
  3002. This plots x squared with title "x^2" and file "data.1" with title
  3003. "measured data":
  3004. .br
  3005.       plot x**2 title "x^2", 'data.1' t "measured data"
  3006. .br
  3007.  
  3008. This puts an untitled circular border around a polar graph:
  3009. .br
  3010.       set polar; plot my_function(t), 1 notitle
  3011. .br
  3012. .sp 2
  3013. .NH 2
  3014. With
  3015. .sp 1
  3016. .LP
  3017. .XS
  3018. With
  3019. .XE
  3020. Functions and data may be displayed in one of a large number of styles.
  3021. The \fBwith\fR keyword provides the means of selection.
  3022.  
  3023. Syntax:
  3024. .br
  3025.       with <style> { {linestyle | ls <line_style>}
  3026. .br
  3027. .br
  3028.                      | {{linetype | lt <line_type>}
  3029. .br
  3030. .br
  3031.                         {linewidth | lw <line_width>}
  3032. .br
  3033. .br
  3034.                         {pointtype | pt <point_type>}
  3035. .br
  3036. .br
  3037.                         {pointsize | ps <point_size>}} }
  3038. .br
  3039.  
  3040. where <style> is either \fBlines\fR, \fBpoints\fR, \fBlinespoints\fR, \fBimpulses\fR, \fBdots\fR,
  3041. \fBsteps\fR, \fBfsteps\fR, \fBhisteps\fR, \fBerrorbars\fR, \fBxerrorbars\fR, \fByerrorbars\fR,
  3042. \fBxyerrorbars\fR, \fBboxes\fR, \fBboxerrorbars\fR, \fBboxxyerrorbars\fR, \fBfinancebars\fR,
  3043. \fBcandlesticks\fR or \fBvector\fR.  Some of these styles require additional
  3044. information.  See \fBset style <style>\fR for details of each style.
  3045.  
  3046. Default styles are chosen with the \fBset function style\fR and \fBset data style\fR
  3047. commands.
  3048.  
  3049. By default, each function and data file will use a different line type and
  3050. point type, up to the maximum number of available types.  All terminal
  3051. drivers support at least six different point types, and re-use them, in
  3052. order, if more are required.  The LaTeX driver supplies an additional six
  3053. point types (all variants of a circle), and thus will only repeat after 12
  3054. curves are plotted with points.  The PostScript drivers (\fBpostscript\fR)
  3055. supplies a total of 64.
  3056.  
  3057. If you wish to choose the line or point type for a single plot, <line_type>
  3058. and <point_type> may be specified.  These are positive integer constants (or
  3059. expressions) that specify the line type and point type to be used for the
  3060. plot.  Use \fBtest\fR to display the types available for your terminal.
  3061.  
  3062. You may also scale the line width and point size for a plot by using
  3063. <line_width> and <point_size>, which are specified relative to the default
  3064. values for each terminal.  The pointsize may also be altered globally---see
  3065. \fBset pointsize\fR for details.  But note that both <point_size> as set here and
  3066. as set by \fBset pointsize\fR multiply the default point size---their effects are
  3067. not cumulative.  That is, \fBset pointsize 2; plot x w p ps 3\fR will use points
  3068. three times default size, not six.
  3069.  
  3070. If you have defined specific line type/width and point type/size combinations
  3071. with \fBset linestyle\fR, one of these may be selected by setting <line_style> to
  3072. the index of the desired style.
  3073.  
  3074. The keywords may be abbreviated as indicated.
  3075.  
  3076. Note that the \fBlinewidth\fR and \fBpointsize\fR options are not supported by all
  3077. terminals.
  3078.  
  3079. Examples:
  3080.  
  3081. This plots sin(x) with impulses:
  3082. .br
  3083.       plot sin(x) with impulses
  3084. .br
  3085.  
  3086. This plots x with points, x**2 with the default:
  3087. .br
  3088.       plot x*y w points, x**2 + y**2
  3089. .br
  3090.  
  3091. This plots tan(x) with the default function style, file "data.1" with lines:
  3092. .br
  3093.       plot [ ] [-2:5] tan(x), 'data.1' with l
  3094. .br
  3095.  
  3096. This plots "leastsq.dat" with impulses:
  3097. .br
  3098.       plot 'leastsq.dat' w i
  3099. .br
  3100.  
  3101. This plots the data file "population" with boxes:
  3102. .br
  3103.       plot 'population' with boxes
  3104. .br
  3105.  
  3106. This plots "exper.dat" with errorbars and lines connecting the points
  3107. (errorbars require three or four columns):
  3108. .br
  3109.       plot 'exper.dat' w lines, 'exper.dat' notitle w errorbars
  3110. .br
  3111.  
  3112. This plots sin(x) and cos(x) with linespoints, using the same line type but
  3113. different point types:
  3114. .br
  3115.       plot sin(x) with linesp lt 1 pt 3, cos(x) with linesp lt 1 pt 4
  3116. .br
  3117.  
  3118. This plots file "data" with points of type 3 and twice usual size:
  3119. .br
  3120.       plot 'data' with points pointtype 3 pointsize 2
  3121. .br
  3122.  
  3123. This plots two data sets with lines differing only by weight:
  3124. .br
  3125.       plot 'd1' t "good" w l lt 2 lw 3, 'd2' t "bad" w l lt 2 lw 1
  3126. .br
  3127.  
  3128. See \fBset style\fR to change the default styles.
  3129. .sp 2
  3130. .RE
  3131. .br
  3132. .NH 1
  3133. Print
  3134. .sp 1
  3135. .LP
  3136. .XS
  3137. Print
  3138. .XE
  3139. The \fBprint\fR command prints the value of <expression> to the screen.  It is
  3140. synonymous with \fBpause 0\fR.  <expression> may be anything that \fBgnuplot\fR can
  3141. evaluate that produces a number, or it can be a string.
  3142.  
  3143. Syntax:
  3144. .br
  3145.       print <expression> {, <expression>, ...}
  3146. .br
  3147.  
  3148. See \fBexpressions\fR.
  3149. .sp 2
  3150. .NH 1
  3151. Pwd
  3152. .sp 1
  3153. .LP
  3154. .XS
  3155. Pwd
  3156. .XE
  3157. The \fBpwd\fR command prints the name of the working directory to the screen.
  3158. .sp 2
  3159. .NH 1
  3160. Quit
  3161. .sp 1
  3162. .LP
  3163. .XS
  3164. Quit
  3165. .XE
  3166. The \fBexit\fR and \fBquit\fR commands and END-OF-FILE character will exit \fBgnuplot\fR.
  3167. Each of these commands will clear the output device (as does the \fBclear\fR
  3168. command) before exiting.
  3169. .sp 2
  3170. .NH 1
  3171. Replot
  3172. .sp 1
  3173. .LP
  3174. .XS
  3175. Replot
  3176. .XE
  3177. The \fBreplot\fR command without arguments repeats the last \fBplot\fR or \fBsplot\fR
  3178. command.  This can be useful for viewing a plot with different \fBset\fR options,
  3179. or when generating the same plot for several devices.
  3180.  
  3181. Arguments specified after a \fBreplot\fR command will be added onto the last
  3182. \fBplot\fR or \fBsplot\fR command (with an implied \&',\&' separator) before it is
  3183. repeated.  \fBreplot\fR accepts the same arguments as the \fBplot\fR and \fBsplot\fR
  3184. commands except that ranges cannot be specified.  Thus you can use \fBreplot\fR
  3185. to plot a function against the second axes if the previous command was \fBplot\fR
  3186. but not if it was \fBsplot\fR, and similarly you can use \fBreplot\fR to add a plot
  3187. from a binary file only if the previous command was \fBsplot\fR.
  3188.  
  3189. N.B.---use of
  3190.  
  3191. .br
  3192.       plot '-' ; ... ; replot
  3193. .br
  3194.  
  3195. is not recommended.  \fBgnuplot\fR does not store the inline data internally, so
  3196. since \fBreplot\fR appends new information to the previous \fBplot\fR and then
  3197. executes the modified command, the \fB\&'-\&'\fR from the initial \fBplot\fR will expect
  3198. to read inline data again.
  3199.  
  3200. Note that \fBreplot\fR does not work in \fBmultiplot\fR mode, since it reproduces
  3201. only the last plot rather than the entire screen.
  3202.  
  3203. See also \fBcommand-line-editing\fR for ways to edit the last \fBplot\fR (\fBsplot\fR)
  3204. command.
  3205. .sp 2
  3206. .NH 1
  3207. Reread
  3208. .sp 1
  3209. .LP
  3210. .XS
  3211. Reread
  3212. .XE
  3213. The \fBreread\fR command causes the current \fBgnuplot\fR command file, as specified
  3214. by a \fBload\fR command or on the command line, to be reset to its starting
  3215. point before further commands are read from it.  This essentially implements
  3216. an endless loop of the commands from the beginning of the command file to
  3217. the \fBreread\fR command.  (But this is not necessarily a disaster---\fBreread\fR can
  3218. be very useful when used in conjunction with \fBif\fR.  See \fBif\fR for details.)
  3219. The \fBreread\fR command has no effect if input from standard input.
  3220.  
  3221. Examples:
  3222.  
  3223. Suppose the file "looper" contains the commands
  3224. .br
  3225.       a=a+1
  3226. .br
  3227. .br
  3228.       plot sin(x*a)
  3229. .br
  3230. .br
  3231.       pause -1
  3232. .br
  3233. .br
  3234.       if(a<5) reread
  3235. .br
  3236. and from within \fBgnuplot\fR you submit the commands
  3237. .br
  3238.       a=0
  3239. .br
  3240. .br
  3241.       load 'looper'
  3242. .br
  3243. The result will be four plots (separated by the \fBpause\fR message).
  3244.  
  3245. Suppose the file "data" contains six columns of numbers with a total yrange
  3246. from 0 to 10; the first is x and the next are five different functions of x.
  3247. Suppose also that the file "plotter" contains the commands
  3248. .br
  3249.       c_p = c_p+1
  3250. .br
  3251. .br
  3252.       plot "$0" using 1:c_p with lines linetype c_p
  3253. .br
  3254. .br
  3255.       if(c_p <  n_p) reread
  3256. .br
  3257. and from within \fBgnuplot\fR you submit the commands
  3258. .br
  3259.       n_p=6
  3260. .br
  3261. .br
  3262.       c_p=1
  3263. .br
  3264. .br
  3265.       set nokey
  3266. .br
  3267. .br
  3268.       set yrange [0:10]
  3269. .br
  3270. .br
  3271.       set multiplot
  3272. .br
  3273. .br
  3274.       call 'plotter' 'data'
  3275. .br
  3276. .br
  3277.       set nomultiplot
  3278. .br
  3279. The result is a single graph consisting of five plots.  The yrange must be
  3280. set explicitly to guarantee that the five separate graphs (drawn on top of
  3281. each other in multiplot mode) will have exactly the same axes.  The linetype
  3282. must be specified; otherwise all the plots would be drawn with the same type.
  3283. .sp 2
  3284. .NH 1
  3285. Reset
  3286. .sp 1
  3287. .LP
  3288. .XS
  3289. Reset
  3290. .XE
  3291. The \fBreset\fR command causes all options that can be set with the \fBset\fR
  3292. command to take on their default values.  The only exceptions are that the
  3293. terminal set with \fBset term\fR and the output file set with \fBset output\fR are
  3294. left unchanged.  This command is useful, e.g., to restore the default
  3295. settings at the end of a command file, or to return to a defined state after
  3296. lots of settings have been changed within a command file.  Please refer to
  3297. the \fBset\fR command to see the default values that the various options take.
  3298. .sp 2
  3299. .NH 1
  3300. Save
  3301. .sp 1
  3302. .LP
  3303. .XS
  3304. Save
  3305. .XE
  3306. The \fBsave\fR command saves user-defined functions, variables, \fBset\fR options,
  3307. or all three, plus the last \fBplot\fR (\fBsplot\fR) command to the specified file.
  3308.  
  3309. Syntax:
  3310. .br
  3311.       save  {<option>} '<filename>'
  3312. .br
  3313.  
  3314. where <option> is \fBfunctions\fR, \fBvariables\fR or \fBset\fR. If no option is used,
  3315. \fBgnuplot\fR saves functions, variables, \fBset\fR options and the last \fBplot\fR
  3316. (\fBsplot\fR) command.
  3317.  
  3318. \fBsave\fRd files are written in text format and may be read by the \fBload\fR
  3319. command.
  3320.  
  3321. The filename must be enclosed in quotes.
  3322.  
  3323. Examples:
  3324. .br
  3325.       save 'work.gnu'
  3326. .br
  3327. .br
  3328.       save functions 'func.dat'
  3329. .br
  3330. .br
  3331.       save var 'var.dat'
  3332. .br
  3333. .br
  3334.       save set 'options.dat'
  3335. .br
  3336. .sp 2
  3337. .NH 1
  3338. Set-show
  3339. .sp 1
  3340. .LP
  3341. .XS
  3342. Set-show
  3343. .XE
  3344. The \fBset\fR command can be used to sets _lots_ of options.  No screen is
  3345. drawn, however, until a \fBplot\fR, \fBsplot\fR, or \fBreplot\fR command is given.
  3346.  
  3347. The \fBshow\fR command shows their settings;  \fBshow all\fR shows all the
  3348. settings.
  3349.  
  3350. If a variable contains time/date data, \fBshow\fR will display it according to
  3351. the format currently defined by \fBset timefmt\fR, even if that was not in effect
  3352. when the variable was initially defined.
  3353. .sp 2
  3354. .RS
  3355. .IP
  3356. .NH 2
  3357. Angles
  3358. .sp 1
  3359. .LP
  3360. .XS
  3361. Angles
  3362. .XE
  3363. By default, \fBgnuplot\fR assumes the independent variable in polar graphs is in
  3364. units of radians.  If \fBset angles degrees\fR is specified before \fBset polar\fR,
  3365. then the default range is [0:360] and the independent variable has units of
  3366. degrees.  This is particularly useful for plots of data files.  The angle
  3367. setting also applies to 3-d mapping as set via the \fBset mapping\fR command.
  3368.  
  3369. Syntax:
  3370. .br
  3371.       set angles {degrees | radians}
  3372. .br
  3373. .br
  3374.       show angles
  3375. .br
  3376.  
  3377. The angle specified in \fBset grid polar\fR is also read and displayed in the
  3378. units specified by \fBset angles\fR.
  3379.  
  3380. \fBset angles\fR also affects the arguments of the machine-defined functions
  3381. sin(x), cos(x) and tan(x), and the outputs of asin(x), acos(x), atan(x),
  3382. atan2(x), and arg(x).  It has no effect on the arguments of hyperbolic
  3383. functions or Bessel functions.  However, the output arguments of inverse
  3384. hyperbolic functions of complex arguments are affected; if these functions
  3385. are used, \fBset angles radians\fR must be in effect to maintain consistency
  3386. between input and output arguments.
  3387.  
  3388. .br
  3389.       x={1.0,0.1}
  3390. .br
  3391. .br
  3392.       set angles radians
  3393. .br
  3394. .br
  3395.       y=sinh(x)
  3396. .br
  3397. .br
  3398.       print y         #prints {1.16933, 0.154051}
  3399. .br
  3400. .br
  3401.       print asinh(y)  #prints {1.0, 0.1}
  3402. .br
  3403. but
  3404. .br
  3405.       set angles degrees
  3406. .br
  3407. .br
  3408.       y=sinh(x)
  3409. .br
  3410. .br
  3411.       print y         #prints {1.16933, 0.154051}
  3412. .br
  3413. .br
  3414.       print asinh(y)  #prints {57.29578, 5.729578}
  3415. .br
  3416. .sp 2
  3417. .NH 2
  3418. Arrow
  3419. .sp 1
  3420. .LP
  3421. .XS
  3422. Arrow
  3423. .XE
  3424. Arbitrary arrows can be placed on a plot using the \fBset arrow\fR command.
  3425.  
  3426. Syntax:
  3427. .br
  3428.       set arrow {<tag>} {from <position>} {to <position>} {{no}head}
  3429. .br
  3430. .br
  3431.                 { {linestyle | ls <line_style>}
  3432. .br
  3433. .br
  3434.                   | {linetype | lt <line_type>}
  3435. .br
  3436. .br
  3437.                     {linewidth | lw <line_width} }
  3438. .br
  3439. .br
  3440.       set noarrow {<tag>}
  3441. .br
  3442. .br
  3443.       show arrow
  3444. .br
  3445.  
  3446. <tag> is an integer that identifies the arrow.  If no tag is given, the
  3447. lowest unused tag value is assigned automatically.  The tag can be used to
  3448. delete or change a specific arrow.  To change any attribute of an existing
  3449. arrow, use the \fBset arrow\fR command with the appropriate tag and specify the
  3450. parts of the arrow to be changed.
  3451.  
  3452. The <position>s are specified by either x,y or x,y,z, and may be preceded by
  3453. \fBfirst\fR, \fBsecond\fR, \fBgraph\fR, or \fBscreen\fR to select the coordinate system.
  3454. Unspecified coordinates default to 0.  The endpoints can be specified in
  3455. one of four coordinate systems---\fBfirst\fR or \fBsecond\fR axes, \fBgraph\fR or
  3456. \fBscreen\fR.  See \fBcoordinates\fR for details.  A coordinate system specifier
  3457. does not carry over from the "from" position to the "to" position.  Arrows
  3458. outside the screen boundaries are permitted but may cause device errors.
  3459.  
  3460. Specifying \fBnohead\fR produces an arrow drawn without a head---a line segment.
  3461. This gives you yet another way to draw a line segment on the plot.  By
  3462. default, arrows have heads.
  3463.  
  3464. The line style may be selected from a user-defined list of line styles (see
  3465. \fBset linestyle\fR) or may be defined here by providing values for <line_type>
  3466. (an index from the default list of styles) and/or <line_width> (which is a
  3467. multiplier for the default width).
  3468.  
  3469. Note, however, that if a user-defined line style has been selected, its
  3470. properties (type and width) cannot be altered merely by issuing another
  3471. \fBset arrow\fR command with the appropriate index and \fBlt\fR or \fBlw\fR.
  3472.  
  3473. Examples:
  3474.  
  3475. To set an arrow pointing from the origin to (1,2) with user-defined style 5,
  3476. use:
  3477. .br
  3478.       set arrow to 1,2 ls 5
  3479. .br
  3480.  
  3481. To set an arrow from bottom left of plotting area to (-5,5,3), and tag the
  3482. arrow number 3, use:
  3483. .br
  3484.       set arrow 3 from graph 0,0 to -5,5,3
  3485. .br
  3486.  
  3487. To change the preceding arrow to end at 1,1,1, without an arrow head and
  3488. double its width, use:
  3489. .br
  3490.       set arrow 3 to 1,1,1 nohead lw 2
  3491. .br
  3492.  
  3493. To draw a vertical line from the bottom to the top of the graph at x=3, use:
  3494. .br
  3495.       set arrow from 3, graph 0 to 3, graph 1 nohead
  3496. .br
  3497.  
  3498. To delete arrow number 2, use:
  3499. .br
  3500.       set noarrow 2
  3501. .br
  3502.  
  3503. To delete all arrows, use:
  3504. .br
  3505.       set noarrow
  3506. .br
  3507.  
  3508. To show all arrows (in tag order), use:
  3509. .br
  3510.       show arrow
  3511. .br
  3512. .sp 2
  3513. .NH 2
  3514. Autoscale
  3515. .sp 1
  3516. .LP
  3517. .XS
  3518. Autoscale
  3519. .XE
  3520. Autoscaling may be set individually on the x, y or z axis or globally on all
  3521. axes. The default is to autoscale all axes.
  3522.  
  3523. Syntax:
  3524. .br
  3525.       set autoscale {<axes>{min|max}}
  3526. .br
  3527. .br
  3528.       set noautoscale {<axes>{min|max}}
  3529. .br
  3530. .br
  3531.       show autoscale
  3532. .br
  3533.  
  3534. where <axes> is either \fBx\fR, \fBy\fR, \fBz\fR, \fBx2\fR, \fBy2\fR or \fBxy\fR.  A keyword with
  3535. \fBmin\fR or \fBmax\fR appended (this cannot be done with \fBxy\fR) tells \fBgnuplot\fR to
  3536. autoscale just the minimum or maximum of that axis.  If no keyword is given,
  3537. all axes are autoscaled.
  3538.  
  3539. When autoscaling, the axis range is automatically computed and the dependent
  3540. axis (y for a \fBplot\fR and z for \fBsplot\fR) is scaled to include the range of the
  3541. function or data being plotted.
  3542.  
  3543. If autoscaling of the dependent axis (y or z) is not set, the current y or z
  3544. range is used.
  3545.  
  3546. Autoscaling the independent variables (x for \fBplot\fR and x,y for \fBsplot\fR) is a
  3547. request to set the domain to match any data file being plotted.  If there are
  3548. no data files, autoscaling an independent variable has no effect.  In other
  3549. words, in the absence of a data file, functions alone do not affect the x
  3550. range (or the y range if plotting z = f(x,y)).
  3551.  
  3552. Please see \fBset xrange\fR for additional information about ranges.
  3553.  
  3554. The behavior of autoscaling remains consistent in parametric mode, (see \fBset
  3555. parametric\fR).  However, there are more dependent variables and hence more
  3556. control over x, y, and z axis scales.  In parametric mode, the independent or
  3557. dummy variable is t for \fBplot\fRs and u,v for \fBsplot\fRs.  \fBautoscale\fR in
  3558. parametric mode, then, controls all ranges (t, u, v, x, y, and z) and allows
  3559. x, y, and z to be fully autoscaled.
  3560.  
  3561. Autoscaling works the same way for polar mode as it does for parametric mode
  3562. for \fBplot\fR, with the extension that in polar mode \fBset dummy\fR can be used to
  3563. change the independent variable from t (see \fBset dummy\fR).
  3564.  
  3565. When tics are displayed on second axes but no plot has been specified for
  3566. those axes, x2range and y2range are inherited from xrange and yrange.  This
  3567. is done _before_ xrange and yrange are autoextended to a whole number of
  3568. tics, which can cause unexpected results.
  3569.  
  3570. Examples:
  3571.  
  3572. This sets autoscaling of the y axis (other axes are not affected):
  3573. .br
  3574.       set autoscale y
  3575. .br
  3576.  
  3577. This sets autoscaling only for the minimum of the y axis (the maximum of the
  3578. y axis and the other axes are not affected):
  3579. .br
  3580.       set autoscale ymin
  3581. .br
  3582.  
  3583. This sets autoscaling of the x and y axes:
  3584. .br
  3585.       set autoscale xy
  3586. .br
  3587.  
  3588. This sets autoscaling of the x, y, z, x2 and y2 axes:
  3589. .br
  3590.       set autoscale
  3591. .br
  3592.  
  3593. This disables autoscaling of the x, y, z, x2 and y2 axes:
  3594. .br
  3595.       set noautoscale
  3596. .br
  3597.  
  3598. This disables autoscaling of the z axis only:
  3599. .br
  3600.       set noautoscale z
  3601. .br
  3602. .sp 2
  3603. .RS
  3604. .IP
  3605. .NH 3
  3606. Parametric mode
  3607. .sp 1
  3608. .LP
  3609. .XS
  3610. Parametric mode
  3611. .XE
  3612. When in parametric mode (\fBset parametric\fR), the xrange is as fully scalable
  3613. as the y range.  In other words, in parametric mode the x axis can be
  3614. automatically scaled to fit the range of the parametric function that is
  3615. being plotted.  Of course, the y axis can also be automatically scaled just
  3616. as in the non-parametric case.  If autoscaling on the x axis is not set, the
  3617. current x range is used.
  3618.  
  3619. Data files are plotted the same in parametric and non-parametric mode.
  3620. However, there is a difference in mixed function and data plots: in
  3621. non-parametric mode with autoscaled x, the x range of the datafile controls
  3622. the x range of the functions; in parametric mode it has no influence.
  3623.  
  3624. For completeness a last command \fBset autoscale t\fR is accepted.  However, the
  3625. effect of this "scaling" is very minor.  When \fBgnuplot\fR determines that the
  3626. t range would be empty, it makes a small adjustment if autoscaling is true.
  3627. Otherwise, \fBgnuplot\fR gives an error.  Such behavior may, in fact, not be very
  3628. useful and the command \fBset autoscale t\fR is certainly questionable.
  3629.  
  3630. \fBsplot\fR extends the above ideas as you would expect.  If autoscaling is set,
  3631. then x, y, and z ranges are computed and each axis scaled to fit the
  3632. resulting data.
  3633. .sp 2
  3634. .NH 3
  3635. Polar mode
  3636. .sp 1
  3637. .LP
  3638. .XS
  3639. Polar mode
  3640. .XE
  3641. When in polar mode (\fBset polar\fR), the xrange and the yrange are both found
  3642. from the polar coordinates, and thus they can both be automatically scaled.
  3643. In other words, in polar mode both the x and y axes can be automatically
  3644. scaled to fit the ranges of the polar function that is being plotted.
  3645.  
  3646. When plotting functions in polar mode, the rrange may be autoscaled.  When
  3647. plotting data files in polar mode, the trange may also be autoscaled.  Note
  3648. that if the trange is contained within one quadrant, autoscaling will produce
  3649. a polar plot of only that single quadrant.
  3650.  
  3651. Explicitly setting one or two ranges but not others may lead to unexpected
  3652. results.
  3653. .sp 2
  3654. .RE
  3655. .br
  3656. .NH 2
  3657. Bar
  3658. .sp 1
  3659. .LP
  3660. .XS
  3661. Bar
  3662. .XE
  3663. The \fBset bar\fR command controls the tics at the ends of errorbars.
  3664.  
  3665. Syntax:
  3666. .br
  3667.       set bar {small | large | <size>}
  3668. .br
  3669. .br
  3670.       show bar
  3671. .br
  3672.  
  3673. \fBsmall\fR is a synonym for 0.0, and \fBlarge\fR for 1.0.
  3674. The default is 1.0 if no size is given.
  3675. .sp 2
  3676. .NH 2
  3677. Bmargin
  3678. .sp 1
  3679. .LP
  3680. .XS
  3681. Bmargin
  3682. .XE
  3683. The command \fBset bmargin\fR sets the size of the bottom margin.  Please see
  3684. \fBset margin\fR for details.
  3685. .sp 2
  3686. .NH 2
  3687. Border
  3688. .sp 1
  3689. .LP
  3690. .XS
  3691. Border
  3692. .XE
  3693. The \fBset border\fR and \fBset noborder\fR commands control the display of the graph
  3694. borders for the \fBplot\fR and \fBsplot\fR commands.
  3695.  
  3696. Syntax:
  3697. .br
  3698.       set border {<integer> { {linestyle | ls <line_style>}
  3699. .br
  3700. .br
  3701.                               | {linetype | lt <line_type> }
  3702. .br
  3703. .br
  3704.                                 {linewidth | lw <line_width>} } }
  3705. .br
  3706. .br
  3707.       set noborder
  3708. .br
  3709. .br
  3710.       show border
  3711. .br
  3712.  
  3713. The borders are encoded in a 12-bit integer: the bottom four bits control the
  3714. border for \fBplot\fR and the sides of the base for \fBsplot\fR; The next four bits
  3715. control the verticals in \fBsplot\fR; the top four bits control the edges on top
  3716. of the \fBsplot\fR.  In detail, the \fB<integer>\fR should be the sum of the
  3717. appropriate entries from the following table:
  3718.  
  3719.  
  3720. .EQ
  3721. delim $$
  3722. .EN
  3723. .KS
  3724. .TS
  3725. center box tab (@) ;
  3726. c c c c c .
  3727. @plot border@splot@splot
  3728. @splot base@verticals@top
  3729. _
  3730. bottom (south)@1@16@256
  3731. left   (west)@2@32@512
  3732. top    (north)@4@64@1024
  3733. right  (east)@8@128@2048
  3734. .TE
  3735. .KE
  3736. .EQ
  3737. delim off
  3738. .EN
  3739.  
  3740.  
  3741. The default is 31, which is all four sides for \fBplot\fR, and base and z axis
  3742. for \fBsplot\fR.
  3743.  
  3744. Using the optional <line_style>, <line_type> and <line_width>
  3745. specifiers, the way the border lines are drawn can be influenced
  3746. (limited by what the current terminal driver supports).  By default,
  3747. the border is drawn with twice the usual linewidth.  The <line_width>
  3748. specifier scales this default value; for example, \fBset border 15 lw 2\fR
  3749. will produce a border with four times the usual linewidth.
  3750.  
  3751. Various axes or combinations of axes may be added together in the command.
  3752.  
  3753. To have tics on edges other than bottom and left, disable the usual tics and
  3754. enable the second axes.
  3755.  
  3756. Examples:
  3757.  
  3758. Draw all borders:
  3759. .br
  3760.       set border
  3761. .br
  3762.  
  3763. Draw only the SOUTHWEST borders:
  3764. .br
  3765.       set border 3
  3766. .br
  3767.  
  3768. Draw a complete box around a \fBsplot\fR:
  3769. .br
  3770.       set border 4095
  3771. .br
  3772.  
  3773. Draw a partial box, omitting the front vertical:
  3774. .br
  3775.       set border 127+256+512
  3776. .br
  3777.  
  3778. Draw only the NORTHEAST borders:
  3779. .br
  3780.       set noxtics; set noytics; set x2tics; set y2tics; set border 12
  3781. .br
  3782.  
  3783. .sp 2
  3784. .NH 2
  3785. Boxwidth
  3786. .sp 1
  3787. .LP
  3788. .XS
  3789. Boxwidth
  3790. .XE
  3791. The \fBset boxwidth\fR command is used to set the default width of boxes in the
  3792. \fBboxes\fR and \fBboxerrorbars\fR styles.
  3793.  
  3794. Syntax:
  3795. .br
  3796.       set boxwidth {<width>}
  3797. .br
  3798. .br
  3799.       show boxwidth
  3800. .br
  3801.  
  3802. If a data file is plotted without the width being specified in the third,
  3803. fourth, or fifth column (or \fBusing\fR entry), or if a function is plotted, the
  3804. width of each box is set by the \fBset boxwidth\fR command.  (If a width is given
  3805. both in the file and by the \fBset boxwidth\fR command, the one in the file is
  3806. used.)  If the width is not specified in one of these ways, the width of each
  3807. box will be calculated automatically so that it touches the adjacent boxes.
  3808. In a four-column data set, the fourth column will be interpreted as the box
  3809. width unless the width is set to -2.0, in which case the width will be
  3810. calculated automatically.  See \fBset style boxerrorbars\fR for more details.
  3811.  
  3812. To set the box width to automatic use the command
  3813. .br
  3814.       set boxwidth
  3815. .br
  3816. or, for four-column data,
  3817. .br
  3818.       set boxwidth -2
  3819. .br
  3820.  
  3821. The same effect can be achieved with the \fBusing\fR keyword in \fBplot\fR:
  3822. .br
  3823.       plot 'file' using 1:2:3:4:(-2)
  3824. .br
  3825. .sp 2
  3826. .NH 2
  3827. Clabel
  3828. .sp 1
  3829. .LP
  3830. .XS
  3831. Clabel
  3832. .XE
  3833. \fBgnuplot\fR will vary the linetype used for each contour level when clabel is
  3834. set.  When this option on (the default), a legend labels each linestyle with
  3835. the z level it represents.  It is not possible at present to separate the
  3836. contour labels from the surface key.
  3837.  
  3838. Syntax:
  3839. .br
  3840.       set clabel {'<format>'}
  3841. .br
  3842. .br
  3843.       set noclabel
  3844. .br
  3845. .br
  3846.       show clabel
  3847. .br
  3848.  
  3849. The default for the format string is %8.3g, which gives three decimal places.
  3850. This may produce poor label alignment if the key is altered from its default
  3851. configuration.
  3852.  
  3853. The first contour linetype, or only contour linetype when clabel is off, is
  3854. the surface linetype +1; contour points are the same style as surface points.
  3855.  
  3856. See also \fBset contour\fR.
  3857. .sp 2
  3858. .NH 2
  3859. Clip
  3860. .sp 1
  3861. .LP
  3862. .XS
  3863. Clip
  3864. .XE
  3865. \fBgnuplot\fR can clip data points and lines that are near the boundaries of a
  3866. graph.
  3867.  
  3868. Syntax:
  3869. .br
  3870.       set clip <clip-type>
  3871. .br
  3872. .br
  3873.       set noclip <clip-type>
  3874. .br
  3875. .br
  3876.       show clip
  3877. .br
  3878.  
  3879. Three clip types are supported by \fBgnuplot\fR: \fBpoints\fR, \fBone\fR, and \fBtwo\fR.
  3880. One, two, or all three clip types may be active for a single graph.
  3881.  
  3882. The \fBpoints\fR clip type forces \fBgnuplot\fR to clip (actually, not plot at all)
  3883. data points that fall within but too close to the boundaries.  This is done
  3884. so that large symbols used for points will not extend outside the boundary
  3885. lines.  Without clipping points near the boundaries, the plot may look bad.
  3886. Adjusting the x and y ranges may give similar results.
  3887.  
  3888. Setting the \fBone\fR clip type causes \fBgnuplot\fR to draw a line segment which has
  3889. only one of its two endpoints within the graph.  Only the in-range portion of
  3890. the line is drawn.  The alternative is to not draw any portion of the line
  3891. segment.
  3892.  
  3893. Some lines may have both endpoints out of range, but pass through the graph.
  3894. Setting the \fBtwo\fR clip-type allows the visible portion of these lines to be
  3895. drawn.
  3896.  
  3897. In no case is a line drawn outside the graph.
  3898.  
  3899. The defaults are \fBnoclip points\fR, \fBclip one\fR, and \fBnoclip two\fR.
  3900.  
  3901. To check the state of all forms of clipping, use
  3902. .br
  3903.       show clip
  3904. .br
  3905.  
  3906. For backward compatibility with older versions, the following forms are also
  3907. permitted:
  3908. .br
  3909.       set clip
  3910. .br
  3911. .br
  3912.       set noclip
  3913. .br
  3914.  
  3915. \fBset clip\fR is synonymous with \fBset clip points\fR; \fBset noclip\fR turns off all
  3916. three types of clipping.
  3917. .sp 2
  3918. .NH 2
  3919. Cntrparam
  3920. .sp 1
  3921. .LP
  3922. .XS
  3923. Cntrparam
  3924. .XE
  3925. \fBset cntrparam\fR controls the generation of contours and their smoothness for
  3926. a contour plot. \fBshow contour\fR displays current settings of \fBcntrparam\fR as
  3927. well as \fBcontour\fR.
  3928.  
  3929. Syntax:
  3930. .br
  3931.       set cntrparam {  {linear | cubicspline | bspline}
  3932. .br
  3933. .br
  3934.                       { points <n>} { order <n> }
  3935. .br
  3936. .br
  3937.                       { levels   auto {<n>} | <n>
  3938. .br
  3939. .br
  3940.                                | discrete <z1> {,<z2>{,<z3>...}}
  3941. .br
  3942. .br
  3943.                                | incremental <start>, <incr> {,<end>}
  3944. .br
  3945. .br
  3946.                        }
  3947. .br
  3948. .br
  3949.                      }
  3950. .br
  3951. .br
  3952.       show contour
  3953. .br
  3954.  
  3955. This command has two functions.  First, it sets the values of z for which
  3956. contour points are to be determined (by linear interpolation between data
  3957. points or function isosamples.)  Second, it controls the way contours are
  3958. drawn between the points determined to be of equal z.  <n> should be an
  3959. integral constant expression and <z1>, <z2> ... any constant expressions.
  3960. The parameters are:
  3961.  
  3962. \fBlinear\fR, \fBcubicspline\fR, \fBbspline\fR---Controls type of approximation or
  3963. interpolation.  If \fBlinear\fR, then straight line segments connect points of
  3964. equal z magnitude.  If \fBcubicspline\fR, then piecewise-linear contours are
  3965. interpolated between the same equal z points to form somewhat smoother
  3966. contours, but which may undulate.  If \fBbspline\fR, a guaranteed-smoother curve
  3967. is drawn, which only approximates the position of the points of equal-z.
  3968.  
  3969. \fBpoints\fR---Eventually all drawings are done with piecewise-linear strokes.
  3970. This number controls the number of line segments used to approximate the
  3971. \fBbspline\fR or \fBcubicspline\fR curve.  Number of cubicspline or bspline
  3972. segments (strokes) = \fBpoints\fR * number of linear segments.
  3973.  
  3974. \fBorder\fR---Order of the bspline approximation to be used.  The bigger this
  3975. order is, the smoother the resulting contour.  (Of course, higher order
  3976. bspline curves will move further away from the original piecewise linear
  3977. data.)  This option is relevant for \fBbspline\fR mode only.  Allowed values are
  3978. integers in the range from 2 (linear) to 10.
  3979.  
  3980. \fBlevels\fR--- Selection of contour levels,  controlled by \fBauto\fR (default),
  3981. \fBdiscrete\fR, \fBincremental\fR, and <n>, number of contour levels, limited to
  3982. .br
  3983.  MAX_DISCRETE_LEVELS as defined in plot.h (30 is standard.)
  3984. .br
  3985.  
  3986. For \fBauto\fR, <n> specifies a nominal number of levels; the actual number will
  3987. be adjusted to give simple labels. If the surface is bounded by zmin and zmax,
  3988. contours will be generated at integer multiples of dz between zmin and zmax,
  3989. where dz is 1, 2, or 5 times some power of ten (like the step between two
  3990. tic marks).
  3991.  
  3992. For \fBlevels discrete\fR, contours will be generated at z = <z1>, <z2> ... as
  3993. specified; the number of discrete levels sets the number of contour levels.
  3994. In \fBdiscrete\fR mode, any \fBset cntrparms levels <n>\fR are ignored.
  3995.  
  3996. For \fBincremental\fR, contours are generated at values of z beginning at <start>
  3997. and increasing by <increment>, until the number of contours is reached. <end>
  3998. is used to determine the number of contour levels, which will be changed by
  3999. any subsequent \fBset cntrparam levels <n>\fR.
  4000.  
  4001. If the command \fBset cntrparam\fR is given without any arguments specified,  the
  4002. defaults are used: linear, 5 points, order 4, 5 auto levels.
  4003.  
  4004. Examples:
  4005. .br
  4006.       set cntrparam bspline
  4007. .br
  4008. .br
  4009.       set cntrparam points 7
  4010. .br
  4011. .br
  4012.       set cntrparam order 10
  4013. .br
  4014.  
  4015. To select levels automatically, 5 if the level increment criteria are met:
  4016. .br
  4017.       set cntrparam levels auto 5
  4018. .br
  4019.  
  4020. To specify discrete levels at .1, .37, and .9:
  4021. .br
  4022.       set cntrparam levels discrete .1,1/exp(1),.9
  4023. .br
  4024.  
  4025. To specify levels from 0 to 4 with increment 1:
  4026. .br
  4027.       set cntrparam levels incremental  0,1,4
  4028. .br
  4029.  
  4030. To set the number of levels to 10 (changing an incremental end or possibly
  4031. the number of auto levels):
  4032. .br
  4033.       set cntrparam levels 10
  4034. .br
  4035.  
  4036. To set the start and increment while retaining the number of levels:
  4037. .br
  4038.       set cntrparam levels incremental 100,50
  4039. .br
  4040.  
  4041. See also \fBset contour\fR for control of where the contours are drawn, and \fBset
  4042. clabel\fR for control of the format of the contour labels and linetypes.
  4043. .sp 2
  4044. .NH 2
  4045. Contour
  4046. .sp 1
  4047. .LP
  4048. .XS
  4049. Contour
  4050. .XE
  4051. \fBset contour\fR enables contour drawing for surfaces. This option is available
  4052. for \fBsplot\fR only.
  4053.  
  4054. Syntax:
  4055. .br
  4056.       set contour {base | surface | both}
  4057. .br
  4058. .br
  4059.       set nocontour
  4060. .br
  4061. .br
  4062.       show contour
  4063. .br
  4064.  
  4065. The three options specify where to draw the contours: \fBbase\fR draws the
  4066. contours on the grid base where the x/ytics are placed, \fBsurface\fR draws the
  4067. contours on the surfaces themselves, and \fBboth\fR draws the contours on both
  4068. the base and the surface.  If no option is provided, the default is \fBbase\fR.
  4069.  
  4070. See also \fBset cntrparam\fR for the parameters that affect the drawing of
  4071. contours, and \fBset clabel\fR for control of labelling of the contours.
  4072.  
  4073. The surface can be switched off (see \fBset surface\fR), giving a contour-only
  4074. graph.  Though it is possible to use \fBset size\fR to enlarge the plot to fill
  4075. the screen, more control over the output format can be obtained by writing
  4076. the contour information to a file, and rereading it as a 2-d datafile plot:
  4077.  
  4078. .br
  4079.       set nosurface
  4080. .br
  4081. .br
  4082.       set contour
  4083. .br
  4084. .br
  4085.       set cntrparam ...
  4086. .br
  4087. .br
  4088.       set term table
  4089. .br
  4090. .br
  4091.       set out 'filename'
  4092. .br
  4093. .br
  4094.       splot ...
  4095. .br
  4096. .br
  4097.       set out
  4098. .br
  4099. .br
  4100.       # contour info now in filename
  4101. .br
  4102. .br
  4103.       set term <whatever>
  4104. .br
  4105. .br
  4106.       plot 'filename'
  4107. .br
  4108.  
  4109. In order to draw contours, the data should be organized as "grid data".  In
  4110. such a file all the points for a single y-isoline are listed, then all the
  4111. points for the next y-isoline, and so on.  A single blank line (a line
  4112. containing no characters other than blank spaces and a carriage return and/or
  4113. a line feed) separates one y-isoline from the next.  See also \fBsplot datafile\fR.
  4114.  
  4115. If contours are desired from non-grid data, \fBset dgrid3d\fR can be used to
  4116. create an appropriate grid.  See \fBset dgrid3d\fR for more information.
  4117. .sp 2
  4118. .NH 2
  4119. Data style
  4120. .sp 1
  4121. .LP
  4122. .XS
  4123. Data style
  4124. .XE
  4125. The \fBset data style\fR command changes the default plotting style for data
  4126. plots.
  4127.  
  4128. Syntax:
  4129. .br
  4130.       set data style <style-choice>
  4131. .br
  4132. .br
  4133.       show data style
  4134. .br
  4135.  
  4136. See \fBset style\fR for the choices.  If no choice is given, the choices are
  4137. listed.  \fBshow data style\fR shows the current default data plotting style.
  4138. .sp 2
  4139. .NH 2
  4140. Dgrid3d
  4141. .sp 1
  4142. .LP
  4143. .XS
  4144. Dgrid3d
  4145. .XE
  4146. The \fBset dgrid3d\fR command enables, and can set parameters for, non-grid
  4147. to grid data mapping.
  4148.  
  4149. Syntax:
  4150. .br
  4151.       set dgrid3d {<row_size>} {,{<col_size>} {,<norm>}}
  4152. .br
  4153. .br
  4154.       set nodgrid3d
  4155. .br
  4156. .br
  4157.       show dgrid3d
  4158. .br
  4159.  
  4160. By default \fBdgrid3d\fR is disabled.  When enabled, 3-d data read from a file
  4161. are always treated as a scattered data set.  A grid with dimensions derived
  4162. from a bounding box of the scattered data and size as specified by the
  4163. row/col_size parameters is created for plotting and contouring.  The grid
  4164. is equally spaced in x (rows) and in y (columns); the z values are computed
  4165. as weighted averages of the scattered points\&' z values.
  4166.  
  4167. The third parameter, norm, controls the weighting:  Each data point is
  4168. weighted inversely by its distance from the grid point raised to the norm
  4169. power.  (Actually, the weights are given by the inverse of dx^norm + dy^norm,
  4170. where dx and dy are the components of the separation of the grid point from
  4171. each data point.  For some norms that are powers of two, specifically 4, 8,
  4172. and 16, the computation is optimized by using the Euclidean distance in the
  4173. weight calculation, (dx^2+dx^2)^norm/2.  However, any non-negative integer
  4174. can be used.)
  4175.  
  4176. The closer the data point is to a grid point, the more effect it has on
  4177. that grid point and the larger the value of norm the less effect more
  4178. distant data points have on that grid point.
  4179.  
  4180. The \fBdgrid3d\fR option is a simple low pass filter that converts scattered
  4181. data to a grid data set.  More sophisticated approaches to this problem
  4182. exist and should be used to preprocess the data outside \fBgnuplot\fR if this
  4183. simple solution is found inadequate.
  4184.  
  4185. (The z values are found by weighting all data points, not by interpolating
  4186. between nearby data points;  also edge effects may produce unexpected and/or
  4187. undesired results.  In some cases, small norm values produce a grid point
  4188. reflecting the average of distant data points rather than a local average,
  4189. while large values of norm may produce "steps" with several grid points
  4190. having the same value as the closest data point, rather than making a smooth
  4191. transition between adjacent data points.  Some areas of a grid may be filled
  4192. by extrapolation, to an arbitrary boundary condition.  The variables are
  4193. not normalized; consequently the units used for x and y will affect the
  4194. relative weights of points in the x and y directions.)
  4195.  
  4196. Examples:
  4197. .br
  4198.       set dgrid3d 10,10,1     # defaults
  4199. .br
  4200. .br
  4201.       set dgrid3d ,,4
  4202. .br
  4203.  
  4204. The first specifies that a grid of size 10 by 10 is to be constructed using
  4205. a norm value of 1 in the weight computation.  The second only modifies the
  4206. norm, changing it to 4.
  4207.  
  4208. .sp 2
  4209. .NH 2
  4210. Dummy
  4211. .sp 1
  4212. .LP
  4213. .XS
  4214. Dummy
  4215. .XE
  4216. The \fBset dummy\fR command changes the default dummy variable names.
  4217.  
  4218. Syntax:
  4219. .br
  4220.       set dummy {<dummy-var>} {,<dummy-var>}
  4221. .br
  4222. .br
  4223.       show dummy
  4224. .br
  4225.  
  4226. By default, \fBgnuplot\fR assumes that the independent, or "dummy", variable for
  4227. the \fBplot\fR command is "t" if in parametric or polar mode, or "x" otherwise.
  4228. Similarly the independent variables for the \fBsplot\fR command are "u" and "v"
  4229. in parametric mode (\fBsplot\fR cannot be used in polar mode), or "x" and "y"
  4230. otherwise.
  4231.  
  4232. It may be more convenient to call a dummy variable by a more physically
  4233. meaningful or conventional name.  For example, when plotting time functions:
  4234.  
  4235. .br
  4236.       set dummy t
  4237. .br
  4238. .br
  4239.       plot sin(t), cos(t)
  4240. .br
  4241.  
  4242. At least one dummy variable must be set on the command; \fBset dummy\fR by itself
  4243. will generate an error message.
  4244.  
  4245. Examples:
  4246. .br
  4247.       set dummy u,v
  4248. .br
  4249. .br
  4250.       set dummy ,s
  4251. .br
  4252.  
  4253. The second example sets the second variable to s.
  4254. .sp 2
  4255. .NH 2
  4256. Encoding
  4257. .sp 1
  4258. .LP
  4259. .XS
  4260. Encoding
  4261. .XE
  4262. The \fBset encoding\fR command selects a character encoding.  Valid values are
  4263. \fBdefault\fR, which tells a terminal to use its default; \fBiso_8859_1\fR (known in
  4264. the PostScript world as \fBISO-Latin1\fR), which is used on many Unix workstations
  4265. and with MS-Windows; \fBcp850\fR, for OS/2; and \fBcp437\fR, for MS-DOS.
  4266.  
  4267. Syntax:
  4268. .br
  4269.       set encoding {<value>}
  4270. .br
  4271. .br
  4272.       show encoding
  4273. .br
  4274.  
  4275. Note that encoding is not supported by all terminal drivers and that
  4276. the device must be able to produce the desired non-standard characters.
  4277. .sp 2
  4278. .NH 2
  4279. Format
  4280. .sp 1
  4281. .LP
  4282. .XS
  4283. Format
  4284. .XE
  4285. The format of the tic-mark labels can be set with the \fBset format\fR command.
  4286.  
  4287. Syntax:
  4288. .br
  4289.       set format {<axes>} {"<format-string>"}
  4290. .br
  4291. .br
  4292.       set format {<axes>} {'<format-string>'}
  4293. .br
  4294. .br
  4295.       show format
  4296. .br
  4297.  
  4298. where <axes> is either \fBx\fR, \fBy\fR, \fBz\fR, \fBxy\fR, \fBx2\fR, \fBy2\fR or nothing (which is
  4299. the same as \fBxy\fR).  The length of the string representing a tic mark (after
  4300. formatting with \&'printf\&') is restricted to 100 characters.  If the format
  4301. string is omitted, the format will be returned to the default "%g".  For
  4302. LaTeX users, the format "$%g$" is often desirable.  If the empty string "" is
  4303. used, no label will be plotted with each tic, though the tic mark will still
  4304. be plotted.  To eliminate all tic marks, use \fBset noxtics\fR or \fBset noytics\fR.
  4305.  
  4306. Newline (\\n) is accepted in the format string.  Use double-quotes rather than
  4307. single-quotes to enable such interpretation.  See also \fBsyntax\fR.
  4308.  
  4309. The default format for both axes is "%g", but other formats such as "%.2f" or
  4310. "%3.0em" are often desirable.  Anything accepted by \&'printf\&' when given a
  4311. double precision number, and accepted by the terminal, will work.  Some other
  4312. options have been added.  If the format string looks like a floating point
  4313. format, then \fBgnuplot\fR tries to construct a reasonable format.
  4314.  
  4315. Characters not preceded by "%" are printed verbatim.  Thus you can include
  4316. spaces and labels in your format string, such as "%g m", which will put " m"
  4317. after each number.  If you want "%" itself, double it: "%g %%".
  4318.  
  4319. See also \fBset xtics\fR for more information about tic labels.
  4320. .sp 2
  4321. .RS
  4322. .IP
  4323. .NH 3
  4324. Format specifiers
  4325. .sp 1
  4326. .LP
  4327. .XS
  4328. Format specifiers
  4329. .XE
  4330. The acceptable formats (if not in time/date mode) are:
  4331.  
  4332.  
  4333. .EQ
  4334. delim $$
  4335. .EN
  4336. .KS
  4337. .TS
  4338. center box tab (@) ;
  4339. c l .
  4340. Format@Explanation
  4341. _
  4342. %f@floating point notation
  4343. %e or %E@exponential notation; an "e" or "E" before the power
  4344. %g or %G@the shorter of %e (or %E) and %f
  4345. %x or %X@hex
  4346. %o or %O@octal
  4347. %t@mantissa to base 10
  4348. %l@mantissa to base of current logscale
  4349. %s@mantissa to base of current logscale; scientific power
  4350. %T@power to base 10
  4351. %L@power to base of current logscale
  4352. %S@scientific power
  4353. %c@character replacement for scientific power
  4354. %P@multiple of pi
  4355. _
  4356. .TE
  4357. .KE
  4358. .EQ
  4359. delim off
  4360. .EN
  4361.  
  4362.  
  4363. A \&'scientific\&' power is one such that the exponent is a multiple of three.
  4364. Character replacement of scientific powers (\fB"%c"\fR) has been implemented
  4365. for powers in the range -18 to +18.  For numbers outside of this range the
  4366. format reverts to exponential.
  4367.  
  4368. Other acceptable modifiers (which come after the "%" but before the format
  4369. specifier) are "-", which left-justifies the number; "+", which forces all
  4370. numbers to be explicitly signed; "#", which places a decimal point after
  4371. floats that have only zeroes following the decimal point; a positive integer,
  4372. which defines the field width; "0" (the digit, not the letter) immediately
  4373. preceding the field width, which indicates that leading zeroes are to be used
  4374. instead of leading blanks; and a decimal point followed by a non-negative
  4375. integer, which defines the precision (the minimum number of digits of an
  4376. integer, or the number of digits following the decimal point of a float).
  4377.  
  4378. Some releases of \&'printf\&' may not support all of these modifiers but may also
  4379. support others; in case of doubt, check the appropriate documentation and
  4380. then experiment.
  4381.  
  4382. Examples:
  4383. .br
  4384.       set format y "%t"; set ytics (5,10)          # "5.0" and "1.0"
  4385. .br
  4386. .br
  4387.       set format y "%s"; set ytics (500,1000)      # "500" and "1.0"
  4388. .br
  4389. .br
  4390.       set format y "+-12.3f"; set ytics(12345)     # "+12345.000  "
  4391. .br
  4392. .br
  4393.       set format y "%.2t*10^%+03T"; set ytic(12345)# "1.23*10^+04"
  4394. .br
  4395. .br
  4396.       set format y "%s*10^{%S}"; set ytic(12345)   # "12.345*10^{3}"
  4397. .br
  4398. .br
  4399.       set format y "%s %cg"; set ytic(12345)       # "12.345 kg"
  4400. .br
  4401. .br
  4402.       set format y "%.0P pi"; set ytic(6.283185)   # "2 pi"
  4403. .br
  4404. .br
  4405.       set format y "%.0P%%"; set ytic(50)          # "50%"
  4406. .br
  4407.  
  4408. .br
  4409.       set log y 2; set format y '%l'; set ytics (1,2,3)
  4410. .br
  4411. .br
  4412.       #displays "1.0", "1.0" and "1.5" (since 3 is 1.5 * 2^1)
  4413. .br
  4414.  
  4415. There are some problem cases that arise when numbers like 9.999 are printed
  4416. with a format that requires both rounding and a power.
  4417.  
  4418. If the data type for the axis is time/date, the format string must contain
  4419. valid codes for the \&'strftime\&' function (outside of \fBgnuplot\fR, type "man
  4420. strftime").  See \fBset timefmt\fR for a list of the allowed input format codes.
  4421. .sp 2
  4422. .NH 3
  4423. Time/date specifiers
  4424. .sp 1
  4425. .LP
  4426. .XS
  4427. Time/date specifiers
  4428. .XE
  4429. In time/date mode, the acceptable formats are:
  4430.  
  4431.  
  4432. .EQ
  4433. delim $$
  4434. .EN
  4435. .KS
  4436. .TS
  4437. center box tab (@) ;
  4438. c l .
  4439. Format@Explanation
  4440. _
  4441. %a@abbreviated name of day of the week
  4442. %A@full name of day of the week
  4443. %b or %h@abbreviated name of the month
  4444. %B@full name of the month
  4445. %d@day of the month, 1--31
  4446. %D@shorthand for "%m/%d/%y"
  4447. %H or %k@hour, 0--24
  4448. %I or %l@hour, 0--12
  4449. %j@day of the year, 1--366
  4450. %m@month, 1--12
  4451. %M@minute, 0--60
  4452. %p@"am" or "pm"
  4453. %r@shorthand for "%I:%M:%S %p"
  4454. %R@shorthand for %H:%M"
  4455. %S@second, 0--60
  4456. %T@shorthand for "%H:%M:%S"
  4457. %U@week of the year (week starts on Sunday)
  4458. %w@day of the week, 0--6 (Sunday = 0)
  4459. %W@week of the year (week starts on Monday)
  4460. %y@year, 0-99
  4461. %Y@year, 4-digit
  4462. _
  4463. .TE
  4464. .KE
  4465. .EQ
  4466. delim off
  4467. .EN
  4468.  
  4469.  
  4470. Except for the non-numerical formats, these may be preceded by a "0" ("zero",
  4471. not "oh") to pad the field length with leading zeroes, and a positive digit,
  4472. to define the minimum field width (which will be overridden if the specified
  4473. width is not large enough to contain the number).  There is a 24-character
  4474. limit to the length of the printed text; longer strings will be truncated.
  4475.  
  4476. Examples:
  4477.  
  4478. Suppose the text is "76/12/25 23:11:11".  Then
  4479. .br
  4480.       set format x                 # defaults to "12/25/76" \\n "23:11"
  4481. .br
  4482. .br
  4483.       set format x "%A, %d %b %Y"  # "Saturday, 25 Dec 1976"
  4484. .br
  4485. .br
  4486.       set format x "%r %d"         # "11:11:11 pm 12/25/76"
  4487. .br
  4488.  
  4489. Suppose the text is "98/07/06 05:04:03".  Then
  4490. .br
  4491.       set format x "%1y/%2m/%3d %01H:%02M:%03S"  # "98/ 7/  6 5:04:003"
  4492. .br
  4493. .sp 2
  4494. .RE
  4495. .br
  4496. .NH 2
  4497. Function style
  4498. .sp 1
  4499. .LP
  4500. .XS
  4501. Function style
  4502. .XE
  4503. The \fBset function style\fR command changes the default plotting style for
  4504. function plots.
  4505.  
  4506. Syntax:
  4507. .br
  4508.       set function style <style-choice>
  4509. .br
  4510. .br
  4511.       show function style
  4512. .br
  4513.  
  4514. See \fBset style\fR for the choices.  If no choice is given, the choices are
  4515. listed.  \fBshow function style\fR shows the current default function plotting
  4516. style.
  4517. .sp 2
  4518. .NH 2
  4519. Functions
  4520. .sp 1
  4521. .LP
  4522. .XS
  4523. Functions
  4524. .XE
  4525. The \fBshow functions\fR command lists all user-defined functions and their
  4526. definitions.
  4527.  
  4528. Syntax:
  4529. .br
  4530.       show functions
  4531. .br
  4532.  
  4533. For information about the definition and usage of functions in \fBgnuplot\fR,
  4534. please see \fBexpressions\fR.
  4535. .sp 2
  4536. .NH 2
  4537. Grid
  4538. .sp 1
  4539. .LP
  4540. .XS
  4541. Grid
  4542. .XE
  4543. The \fBset grid\fR command allows grid lines to be drawn on the plot.
  4544.  
  4545. Syntax:
  4546. .br
  4547.       set grid {{no}{m}xtics} {{no}{m}ytics} {{no}{m}ztics}
  4548. .br
  4549. .br
  4550.                {{no}{m}x2tics} {{no}{m}y2tics}
  4551. .br
  4552. .br
  4553.                {polar {<angle>}}
  4554. .br
  4555. .br
  4556.                { {linestyle <major_linestyle>}
  4557. .br
  4558. .br
  4559.                  | {linetype | lt <major_linetype>}
  4560. .br
  4561. .br
  4562.                    {linewidth | lw <major_linewidth>}
  4563. .br
  4564. .br
  4565.                  { , {linestyle | ls <minor_linestyle>}
  4566. .br
  4567. .br
  4568.                      | {linetype | lt <minor_linetype>}
  4569. .br
  4570. .br
  4571.                        {linewidth | lw <minor_linewidth>} } }
  4572. .br
  4573. .br
  4574.       set nogrid
  4575. .br
  4576. .br
  4577.       show grid
  4578. .br
  4579.  
  4580. The grid can be enabled and disabled for the major and/or minor tic
  4581. marks on any axis, and the linetype and linewidth can be specified
  4582. for major and minor grid lines, also via a predefined linestyle, as
  4583. far as the active terminal driver supports this.
  4584.  
  4585. Additionally, a polar grid can be selected for 2-d plots---circles are drawn
  4586. to intersect the selected tics, and radial lines are drawn at definable
  4587. intervals.  (The interval is given in degrees or radians ,depending on the
  4588. \fBset angles\fR setting.)  Note that a polar grid is no longer automatically
  4589. generated in polar mode.
  4590.  
  4591. The pertinent tics must be enabled before \fBset grid\fR can draw them; \fBgnuplot\fR
  4592. will quietly ignore instructions to draw grid lines at non-existent tics, but
  4593. they will appear if the tics are subsequently enabled.
  4594.  
  4595. If no linetype is specified for the minor gridlines, the same linetype as the
  4596. major gridlines is used.  The default polar angle is 30 degrees.
  4597.  
  4598. By default, grid lines are drawn with half the usual linewidth. The major and
  4599. minor linewidth specifiers scale this default value; for example, \fBset grid
  4600. lw .5\fR will draw grid lines with one quarter the usual linewidth.
  4601.  
  4602. Z grid lines are drawn on the back of the plot.  This looks better if a
  4603. partial box is drawn around the plot---see \fBset border\fR.
  4604. .sp 2
  4605. .NH 2
  4606. Hidden3d
  4607. .sp 1
  4608. .LP
  4609. .XS
  4610. Hidden3d
  4611. .XE
  4612. The \fBset hidden3d\fR command enables hidden line removal for surface plotting
  4613. (see \fBsplot\fR).  Some optional features of the underlying algorithm can also
  4614. be controlled using this command.
  4615.  
  4616. Syntax:
  4617. .br
  4618.       set hidden3d {defaults} |
  4619. .br
  4620. .br
  4621.                    { {{offset <offset>} | {nooffset}}
  4622. .br
  4623. .br
  4624.                      {trianglepattern <bitpattern>}
  4625. .br
  4626. .br
  4627.                      {{undefined <level>} | {noundefined}}
  4628. .br
  4629. .br
  4630.                      {{no}altdiagonal}
  4631. .br
  4632. .br
  4633.                      {{no}bentover} }
  4634. .br
  4635. .br
  4636.       set nohidden3d
  4637. .br
  4638. .br
  4639.       show hidden3d
  4640. .br
  4641.  
  4642. In contrast to the usual display in gnuplot, hidden line removal actually
  4643. treats the given function or data grids as real surfaces that can\&'t be seen
  4644. through, so parts behind the surface will be hidden by it.  For this to be
  4645. possible, the surface needs to have \&'grid structure\&' (see \fBsplot datafile\fR
  4646. about this), and it has to be drawn \fBwith lines\fR or \fBwith linespoints\fR.
  4647.  
  4648. When \fBhidden3d\fR is set, both the hidden portion of the surface and possibly
  4649. its contours drawn on the base (see \fBset contour\fR) as well as the grid will
  4650. be hidden.  Each surface has its hidden parts removed with respect to itself
  4651. and to other surfaces, if more than one surface is plotted.  Contours drawn
  4652. on the surface (\fBset contour surface\fR) don\&'t work.  Labels and arrows are
  4653. always visible and are unaffected.  The key is also never hidden by the
  4654. surface.
  4655.  
  4656. Functions are evaluated at isoline intersections.  The algorithm interpolates
  4657. linearly between function points or data points when determining the visible
  4658. line segments.  This means that the appearance of a function may be different
  4659. when plotted with \fBhidden3d\fR than when plotted with \fBnohidden3d\fR because in
  4660. the latter case functions are evaluated at each sample.  Please see \fBset
  4661. samples\fR and \fBset isosamples\fR for discussion of the difference.
  4662.  
  4663. The algorithm used to remove the hidden parts of the surfaces has some
  4664. additional features controllable by this command.  Specifying \fBdefaults\fR will
  4665. set them all to their default settings, as detailed below.  If \fBdefaults\fR is
  4666. not given, only explicitly specified options will be influenced: all others
  4667. will keep their previous values, so you can turn on/off hidden line removal
  4668. via \fBset {no}hidden3d\fR, without modifying the set of options you chose.
  4669.  
  4670. The first option, \fBoffset\fR, influences the linestyle used for lines on the
  4671. \&\&'back\&' side.  Normally, they are drawn in a linestyle one index number higher
  4672. than the one used for the front, to make the two sides of the surface
  4673. distinguishable.  You can specify a different line style offset to add
  4674. instead of the default 1, by \fBoffset <offset>\fR.  Option \fBnooffset\fR stands for
  4675. \fBoffset 0\fR, making the two sides of the surface use the same linestyle.
  4676.  
  4677. Next comes the option \fBtrianglepattern <bitpattern>\fR.  <bitpattern> must be
  4678. a number between 0 and 7, interpreted as a bit pattern.  Each bit determines
  4679. the visibility of one edge of the triangles each surface is split up into.
  4680. Bit 0 is for the \&'horizontal\&' edges of the grid, Bit 1 for the \&'vertical\&'
  4681. ones, and Bit 2 for the diagonals that split each cell of the original grid
  4682. into two triangles.  The default pattern is 3, making all horizontal and
  4683. vertical lines visible, but not the diagonals.  You may want to choose 7 to
  4684. see those diagonals as well.
  4685.  
  4686. The \fBundefined <level>\fR option lets you decide what the algorithm is to do
  4687. with data points that are undefined (missing data, or undefined function
  4688. values), or exceed the given x-, y- or z-ranges.  Such points can either be
  4689. plotted nevertheless, or taken out of the input data set.  All surface
  4690. elements touching a point that is taken out will be taken out as well, thus
  4691. creating a hole in the surface.  If <level> = 3, equivalent to option
  4692. \fBnoundefined\fR, no points will be thrown away at all.  This may produce all
  4693. kinds of problems elsewhere, so you should avoid this.  <level> = 2 will
  4694. throw away undefined points, but keep the out-of-range ones.  <level> = 1,
  4695. the default, will get rid of out-of-range points as well.
  4696.  
  4697. By specifying \fBnoaltdiagonal\fR, you can override the default handling of a
  4698. special case can occur if \fBundefined\fR is active (i.e. <level> is not 3).
  4699. Each cell of the grid-structured input surface will be divided in two
  4700. triangles along one of its diagonals.  Normally, all these diagonals have
  4701. the same orientation relative to the grid.  If exactly one of the four cell
  4702. corners is excluded by the \fBundefined\fR handler, and this is on the usual
  4703. diagonal, both triangles will be excluded.  However if the default setting
  4704. of \fBaltdiagonal\fR is active, the other diagonal will be chosen for this cell
  4705. instead, minimizing the size of the hole in the surface.
  4706.  
  4707. The \fBbentover\fR option controls what happens to another special case, this
  4708. time in conjunction with the \fBtrianglepattern\fR.  For rather crumply surfaces,
  4709. it can happen that the two triangles a surface cell is divided into are seen
  4710. from opposite sides (i.e. the original quadrangle is \&'bent over\&'), as
  4711. illustrated in the following ASCII art:
  4712.  
  4713. .br
  4714.                                                               C----B
  4715. .br
  4716. .br
  4717.     original quadrangle:  A--B      displayed quadrangle:     |\\   |
  4718. .br
  4719. .br
  4720.       ("set view 0,0")    | /|    ("set view 75,75" perhaps)  | \\  |
  4721. .br
  4722. .br
  4723.                           |/ |                                |  \\ |
  4724. .br
  4725. .br
  4726.                           C--D                                |   \\|
  4727. .br
  4728. .br
  4729.                                                               A    D
  4730. .br
  4731.  
  4732. If the diagonal edges of the surface cells aren\&'t generally made visible by
  4733. bit 2 of the <bitpattern> there, the edge CB above wouldn\&'t be drawn at all,
  4734. normally, making the resulting display hard to understand.  Therefore, the
  4735. default option of \fBbentover\fR will turn it visible in this case.  If you don\&'t
  4736. want that, you may choose \fBnobentover\fR instead.
  4737. .sp 2
  4738. .NH 2
  4739. Isosamples
  4740. .sp 1
  4741. .LP
  4742. .XS
  4743. Isosamples
  4744. .XE
  4745. The isoline density (grid) for plotting functions as surfaces may be changed
  4746. by the \fBset isosamples\fR command.
  4747.  
  4748. Syntax:
  4749. .br
  4750.       set isosamples <iso_1> {,<iso_2>}
  4751. .br
  4752. .br
  4753.       show isosamples
  4754. .br
  4755.  
  4756. Each function surface plot will have <iso_1> iso-u lines and <iso_2> iso-v
  4757. lines.  If you only specify <iso_1>, <iso_2> will be set to the same value
  4758. as <iso_1>.  By default, sampling is set to 10 isolines per u or v axis.
  4759. A higher sampling rate will produce more accurate plots, but will take longer.
  4760. These parameters have no effect on data file plotting.
  4761.  
  4762. An isoline is a curve parameterized by one of the surface parameters while
  4763. the other surface parameter is fixed.  Isolines provide a simple means to
  4764. display a surface.  By fixing the u parameter of surface s(u,v), the iso-u
  4765. lines of the form c(v) = s(u0,v) are produced, and by fixing the v parameter,
  4766. the iso-v lines of the form c(u) = s(u,v0) are produced.
  4767.  
  4768. When a function surface plot is being done without the removal of hidden
  4769. lines, \fBset samples\fR  controls the number of points sampled along each
  4770. isoline;  see \fBset samples\fR and \fBset hidden3d\fR.  The contour algorithm
  4771. assumes that a function sample occurs at each isoline intersection, so
  4772. change in \fBsamples\fR as well as \fBisosamples\fR may be desired when changing
  4773. the resolution of a function surface/contour.
  4774. .sp 2
  4775. .NH 2
  4776. Key
  4777. .sp 1
  4778. .LP
  4779. .XS
  4780. Key
  4781. .XE
  4782. The \fBset key\fR enables a key (or legend) describing plots on a plot.
  4783.  
  4784. The contents of the key, i.e., the names given to each plotted data set and
  4785. function and samples of the lines and/or symbols used to represent them, are
  4786. determined by the \fBtitle\fR and \fBwith\fR options of the {\fBs\fR}\fBplot\fR command.
  4787. Please see \fBplot title\fR and \fBplot with\fR for more information.
  4788.  
  4789. Syntax:
  4790. .br
  4791.       set key {  left | right | top | bottom | outside | below
  4792. .br
  4793. .br
  4794.                | <position>}
  4795. .br
  4796. .br
  4797.               {Left | Right} {{no}reverse}
  4798. .br
  4799. .br
  4800.               {samplen <sample_length>} {spacing <vertical_spacing>}
  4801. .br
  4802. .br
  4803.               {width <width_increment>}
  4804. .br
  4805. .br
  4806.               {title "<text>"}
  4807. .br
  4808. .br
  4809.               {{no}box { {linestyle | ls <line_style>}
  4810. .br
  4811. .br
  4812.                          | {linetype | lt <line_type>}
  4813. .br
  4814. .br
  4815.                            {linewidth | lw <line_width>}}}
  4816. .br
  4817. .br
  4818.       set nokey
  4819. .br
  4820. .br
  4821.       show key
  4822. .br
  4823.  
  4824. By default the key is placed in the upper right corner of the graph.  The
  4825. keywords \fBleft\fR, \fBright\fR, \fBtop\fR, \fBbottom\fR, \fBoutside\fR and \fBbelow\fR may be used
  4826. to place the key in the other corners inside the graph or to the right
  4827. (outside) or below the graph.  They may be given alone or combined.
  4828.  
  4829. Justification of the labels within the key is controlled by \fBLeft\fR or \fBRight\fR
  4830. (default is \fBRight\fR).  The text and sample can be reversed (\fBreverse\fR) and a
  4831. box can be drawn around the key (\fBbox {...}\fR) in a specified \fBlinetype\fR
  4832. and \fBlinewidth\fR, or a user-defined \fBlinestyle\fR. Note that not all
  4833. terminal drivers support linewidth selection, though.
  4834.  
  4835. The length of the sample line can be controlled by \fBsamplen\fR.  The sample
  4836. length is computed as the sum of the tic length and <sample_length> times the
  4837. character width.  \fBsamplen\fR also affects the positions of point samples in
  4838. the key since these are drawn at the midpoint of the sample line, even if it
  4839. is not drawn.  <sample_length> must be an integer.
  4840.  
  4841. The vertical spacing between lines is controlled by \fBspacing\fR.  The spacing
  4842. is set equal to the product of the pointsize, the vertical tic size, and
  4843. <vertical_spacing>.  The program will guarantee that the vertical spacing is
  4844. no smaller than the character height.
  4845.  
  4846. The <width_increment> is a number of character widths to be added to or
  4847. subtracted from the length of the string.  This is useful only when you are
  4848. putting a box around the key and you are using control characters in the text.
  4849. \fBgnuplot\fR simply counts the number of characters in the string when computing
  4850. the box width; this allows you to correct it.
  4851.  
  4852. A title can be put on the key (\fBtitle "<text>"\fR)---see also \fBsyntax\fR for the
  4853. distinction between text in single- or double-quotes.  The key title uses the
  4854. same justification as do the plot titles.
  4855.  
  4856. The defaults for \fBset key\fR are \fBright\fR, \fBtop\fR, \fBRight\fR, \fBnoreverse\fR, \fBsamplen
  4857. 4\fR, \fBspacing 1.25\fR, \fBtitle ""\fR, and \fBnobox\fR.  The default <linetype> is the
  4858. same as that used for the plot borders.  Entering \fBset key\fR with no options
  4859. returns the key to its default configuration.
  4860.  
  4861. The <position> can be a simple x,y,z as in previous versions, but these can
  4862. be preceded by one of four keywords (\fBfirst\fR, \fBsecond\fR, \fBgraph\fR, \fBscreen\fR)
  4863. which selects the coordinate system in which the position is specified.  See
  4864. \fBcoordinates\fR for more details.
  4865.  
  4866. The key is drawn as a sequence of lines, with one plot described on each
  4867. line.  On the right-hand side (or the left-hand side, if \fBreverse\fR is
  4868. selected) of each line is a representation that attempts to mimic the way the
  4869. curve is plotted.  On the other side of each line is the text description
  4870. (the line title), obtained from the \fBplot\fR command.  The lines are vertically
  4871. arranged so that an imaginary straight line divides the left- and right-hand
  4872. sides of the key.  It is the coordinates of the top of this line that are
  4873. specified with the \fBset key\fR command.  In a \fBplot\fR, only the x and y
  4874. coordinates are used to specify the line position.  For a \fBsplot\fR, x, y and
  4875. z are all used as a 3-d location mapped using the same mapping as the graph
  4876. itself to form the required 2-d screen position of the imaginary line.
  4877.  
  4878. Some or all of the key may be outside of the graph boundary, although this
  4879. may interfere with other labels and may cause an error on some devices.  If
  4880. you use the keywords \fBoutside\fR or \fBbelow\fR, \fBgnuplot\fR makes space for the keys
  4881. and the graph becomes smaller.  Putting keys outside to the right, they
  4882. occupy as few columns as possible, and putting them below, as many columns as
  4883. possible (depending of the length of the labels), thus stealing as little
  4884. space from the graph as possible.
  4885.  
  4886. When using the TeX or PostScript drivers, or similar drivers where formatting
  4887. information is embedded in the string, \fBgnuplot\fR is unable to calculate
  4888. correctly the width of the string for key positioning.  If the key is to be
  4889. positioned at the left, it may be convenient to use the combination  \fBset key
  4890. left Left reverse\fR.  The box and gap in the grid will be the width of the
  4891. literal string.
  4892.  
  4893. If \fBsplot\fR is being used to draw contours, the contour labels will be listed
  4894. in the key.  If the alignment of these labels is poor or a different number
  4895. of decimal places is desired, the label format can be specified.  See \fBset
  4896. clabel\fR for details.
  4897.  
  4898. Examples:
  4899.  
  4900. This places the key at the default location:
  4901. .br
  4902.       set key
  4903. .br
  4904.  
  4905. This disables the key:
  4906. .br
  4907.       set nokey
  4908. .br
  4909.  
  4910. This places a key at coordinates 2,3.5,2 in the default (first) coordinate
  4911. system:
  4912. .br
  4913.       set key 2,3.5,2
  4914. .br
  4915.  
  4916. This places the key below the graph:
  4917. .br
  4918.       set key below
  4919. .br
  4920.  
  4921. This places the key in the bottom left corner, left-justifies the text,
  4922. gives it a title, and draws a box around it in linetype 3:
  4923. .br
  4924.       set key left bottom Left title 'Legend' box 3
  4925. .br
  4926. .sp 2
  4927. .NH 2
  4928. Label
  4929. .sp 1
  4930. .LP
  4931. .XS
  4932. Label
  4933. .XE
  4934. Arbitrary labels can be placed on the plot using the \fBset label\fR command.
  4935.  
  4936. Syntax:
  4937. .br
  4938.       set label {<tag>} {"<label_text>"} {at <position>}
  4939. .br
  4940. .br
  4941.                 {<justification>} {{no}rotate} {font "<name><,size>"}
  4942. .br
  4943. .br
  4944.       set nolabel {<tag>}
  4945. .br
  4946. .br
  4947.       show label
  4948. .br
  4949.  
  4950. The <position> is specified by either x,y or x,y,z, and may be preceded by
  4951. \fBfirst\fR, \fBsecond\fR, \fBgraph\fR, or \fBscreen\fR to select the coordinate system.
  4952. See \fBcoordinates\fR for details.
  4953.  
  4954. The tag is an integer that is used to identify the label. If no <tag> is
  4955. given, the lowest unused tag value is assigned automatically.  The tag can be
  4956. used to delete or modify a specific label.  To change any attribute of an
  4957. existing label, use the \fBset label\fR command with the appropriate tag, and
  4958. specify the parts of the label to be changed.
  4959.  
  4960. By default, the text is placed flush left against the point x,y,z.  To adjust
  4961. the way the label is positioned with respect to the point x,y,z, add the
  4962. parameter <justification>, which may be \fBleft\fR, \fBright\fR or \fBcenter\fR,
  4963. indicating that the point is to be at the left, right or center of the text.
  4964. Labels outside the plotted boundaries are permitted but may interfere with
  4965. axis labels or other text.
  4966.  
  4967. If \fBrotate\fR is given, the label is written vertically (if the terminal can do
  4968. so, of course).
  4969.  
  4970. If one (or more) axis is timeseries, the appropriate coordinate should be
  4971. given as a quoted time string according to the \fBtimefmt\fR format string.  See
  4972. \fBset xdata\fR and \fBset timefmt\fR.
  4973.  
  4974. The EEPIC, Imagen, LaTeX, and TPIC drivers allow \\\\ in a string to specify
  4975. a newline.
  4976.  
  4977. Examples:
  4978.  
  4979. To set a label at (1,2) to "y=x", use:
  4980. .br
  4981.       set label "y=x" at 1,2
  4982. .br
  4983.  
  4984. To set a Sigma of size 24, from the Symbol font set, at the center of
  4985. the graph, use:
  4986. .br
  4987.       set label "S" at graph 0.5,0.5 center font "Symbol,24"
  4988. .br
  4989.  
  4990. To set a label "y=x^2" with the right of the text at (2,3,4), and tag the
  4991. label as number 3, use:
  4992. .br
  4993.       set label 3 "y=x^2" at 2,3,4 right
  4994. .br
  4995.  
  4996. To change the preceding label to center justification, use:
  4997. .br
  4998.       set label 3 center
  4999. .br
  5000.  
  5001. To delete label number 2, use:
  5002. .br
  5003.       set nolabel 2
  5004. .br
  5005.  
  5006. To delete all labels, use:
  5007. .br
  5008.       set nolabel
  5009. .br
  5010.  
  5011. To show all labels (in tag order), use:
  5012. .br
  5013.       show label
  5014. .br
  5015.  
  5016. To set a label on a graph with a timeseries on the x axis, use, for example:
  5017. .br
  5018.       set timefmt "%d/%m/%y,%H:%M"
  5019. .br
  5020. .br
  5021.       set label "Harvest" at "25/8/93",1
  5022. .br
  5023. .sp 2
  5024. .NH 2
  5025. Linestyle
  5026. .sp 1
  5027. .LP
  5028. .XS
  5029. Linestyle
  5030. .XE
  5031. Each terminal has a default set of line and point types, which can be seen
  5032. by using the command \fBtest\fR.  \fBset linestyle\fR defines a set of line types
  5033. and widths and point types and sizes so that you can refer to them later by
  5034. an index instead of repeating all the information at each invocation.
  5035.  
  5036. Syntax:
  5037. .br
  5038.       set linestyle <index> {linetype | lt <line_type>}
  5039. .br
  5040. .br
  5041.                             {linewidth | lw <line_width>}
  5042. .br
  5043. .br
  5044.                             {pointtype | pt <point_type>}
  5045. .br
  5046. .br
  5047.                             {pointsize | ps <point_size>}
  5048. .br
  5049. .br
  5050.       set nolinestyle
  5051. .br
  5052. .br
  5053.       show linestyle
  5054. .br
  5055.  
  5056. The line and point types are taken from the default types for the terminal
  5057. currently in use.  The line width and point size are multipliers for the
  5058. default width and size (but note that <point_size> here is unaffected by
  5059. the multiplier given on \&'set pointsize\&').
  5060.  
  5061. The defaults for the line and point types is the index.  The defaults for
  5062. the width and size are both unity.
  5063.  
  5064. Linestyles created by this mechanism do not replace the default styles;
  5065. both may be used.
  5066.  
  5067. Not all terminals support the \fBlinewidth\fR and \fBpointsize\fR features; if
  5068. not supported, the option will be ignored.
  5069.  
  5070. Note that this feature is not completely implemented; linestyles defined by
  5071. this mechanism may be used with \&'plot\&', \&'splot\&', \&'replot\&', and \&'set arrow\&',
  5072. but not by other commands that allow the default index to be used, such as
  5073. \&\&'set grid\&'.
  5074.  
  5075. Example:
  5076. Suppose that the default lines for indices 1, 2, and 3 are red, green, and
  5077. blue, respectively, and the default point shapes for the same indices are a
  5078. square, a cross, and a triangle, respectively.  Then
  5079.  
  5080. .br
  5081.       set linestyle 1 lt 2 lw 2 pt 3 ps 0.5
  5082. .br
  5083.  
  5084. defines a new linestyle that is green and twice the default width and a new
  5085. pointstyle that is a half-sized triangle.  The commands
  5086.  
  5087. .br
  5088.       set function style lines
  5089. .br
  5090. .br
  5091.       plot f(x) lt 3, g(x) ls 1
  5092. .br
  5093.  
  5094. will create a plot of f(x) using the default blue line and a plot of g(x)
  5095. using the user-defined wide green line.  Similarly the commands
  5096.  
  5097. .br
  5098.       set function style linespoints
  5099. .br
  5100. .br
  5101.       plot p(x) lt 1 pt 3, q(x) ls 1
  5102. .br
  5103.  
  5104. will create a plot of f(x) using the default triangles connected by a red
  5105. line and q(x) using small triangles connected by a green line.
  5106. .sp 2
  5107. .NH 2
  5108. Lmargin
  5109. .sp 1
  5110. .LP
  5111. .XS
  5112. Lmargin
  5113. .XE
  5114. The command \fBset lmargin\fR sets the size of the left margin.  Please see
  5115. \fBset margin\fR for details.
  5116. .sp 2
  5117. .NH 2
  5118. Locale
  5119. .sp 1
  5120. .LP
  5121. .XS
  5122. Locale
  5123. .XE
  5124. The \fBlocale\fR setting determines the language with which \fB{x,y,z}{d,m}tics\fR
  5125. will write the days and months.
  5126.  
  5127. Syntax:
  5128. .br
  5129.       set locale {"<locale>"}
  5130. .br
  5131.  
  5132. <locale> may be any language designation acceptable to your installation.
  5133. See your system documentation for the available options.  The default value
  5134. is determined from the LANG environment variable.
  5135. .sp 2
  5136. .NH 2
  5137. Logscale
  5138. .sp 1
  5139. .LP
  5140. .XS
  5141. Logscale
  5142. .XE
  5143. Log scaling may be set on the x, y, z, x2 and/or y2 axes.
  5144.  
  5145. Syntax:
  5146. .br
  5147.       set logscale <axes> <base>
  5148. .br
  5149. .br
  5150.       set nologscale <axes>
  5151. .br
  5152. .br
  5153.       show logscale
  5154. .br
  5155.  
  5156. where <axes> may be any combinations of \fBx\fR, \fBy\fR, and \fBz\fR, in any order, or
  5157. \fBx2\fR or \fBy2\fR and where <base> is the base of the log scaling.  If <base> is
  5158. not given, then 10 is assumed.  If <axes> is not given, then all axes are
  5159. assumed.  \fBset nologscale\fR turns off log scaling for the specified axes.
  5160.  
  5161. Examples:
  5162.  
  5163. To enable log scaling in both x and z axes:
  5164. .br
  5165.       set logscale xz
  5166. .br
  5167.  
  5168. To enable scaling log base 2 of the y axis:
  5169. .br
  5170.       set logscale y 2
  5171. .br
  5172.  
  5173. To disable z axis log scaling:
  5174. .br
  5175.       set nologscale z
  5176. .br
  5177. .sp 2
  5178. .NH 2
  5179. Mapping
  5180. .sp 1
  5181. .LP
  5182. .XS
  5183. Mapping
  5184. .XE
  5185. If data are provided to \fBsplot\fR in spherical or cylindrical coordinates,
  5186. the \fBset mapping\fR command should be used to instruct \fBgnuplot\fR how to
  5187. interpret them.
  5188.  
  5189. Syntax:
  5190. .br
  5191.       set mapping {cartesian | spherical | cylindrical}
  5192. .br
  5193.  
  5194. A cartesian coordinate system is used by default.
  5195.  
  5196. For a spherical coordinate system, the data occupy two or three columns (or
  5197. \fBusing\fR entries).  The first two are interpreted as the polar and azimuthal
  5198. angles theta and phi (in the units specified by \fBset angles\fR).  The radius r
  5199. is taken from the third column if there is one, or is set to unity if there
  5200. is no third column.  The mapping is:
  5201.  
  5202. .br
  5203.       x = r * cos(theta) * cos(phi)
  5204. .br
  5205. .br
  5206.       y = r * sin(theta) * cos(phi)
  5207. .br
  5208. .br
  5209.       z = r * sin(phi)
  5210. .br
  5211.  
  5212. Note that this is a "geographic" spherical system, rather than a "polar" one.
  5213.  
  5214. For a cylindrical coordinate system, the data again occupy two or three
  5215. columns.  The first two are interpreted as theta (in the units specified by
  5216. \fBset angles\fR) and z.  The radius is either taken from the third column or set
  5217. to unity, as in the spherical case.  The mapping is:
  5218.  
  5219. .br
  5220.       x = r * cos(theta)
  5221. .br
  5222. .br
  5223.       y = r * sin(theta)
  5224. .br
  5225. .br
  5226.       z = z
  5227. .br
  5228.  
  5229. The effects of \fBmapping\fR can be duplicated with the \fBusing\fR filter on the
  5230. \fBsplot\fR command, but \fBmapping\fR may be more convenient if many data files are
  5231. to be processed.  However even if \fBmapping\fR is used, \fBusing\fR may still be
  5232. necessary if the data in the file are not in the required order.
  5233.  
  5234. \fBmapping\fR has no effect on \fBplot\fR.
  5235. .sp 2
  5236. .NH 2
  5237. Margin
  5238. .sp 1
  5239. .LP
  5240. .XS
  5241. Margin
  5242. .XE
  5243. The computed margins can be overridden by the \fBset margin\fR commands.  \fBshow
  5244. margin\fR shows the current settings.
  5245.  
  5246. Syntax:
  5247. .br
  5248.       set bmargin {<margin>}
  5249. .br
  5250. .br
  5251.       set lmargin {<margin>}
  5252. .br
  5253. .br
  5254.       set rmargin {<margin>}
  5255. .br
  5256. .br
  5257.       set tmargin {<margin>}
  5258. .br
  5259. .br
  5260.       show margin
  5261. .br
  5262.  
  5263. The units of <margin> are character heights or widths, as appropriate.  A
  5264. positive value defines the absolute size of the margin.  A negative value
  5265. (or none) causes \fBgnuplot\fR to revert to the computed value.
  5266.  
  5267. Normally the margins of a plot are automatically calculated based on tics,
  5268. tic labels, axis labels, the plot title, the timestamp and the size of the
  5269. key if it is outside the borders.  If, however, tics are attached to the
  5270. axes (\fBset xtics axis\fR, for example), neither the tics themselves nor their
  5271. labels will be included in either the margin calculation or the calculation
  5272. of the positions of other text to be written in the margin.  This can lead
  5273. to tic labels overwriting other text if the axis is very close to the border.
  5274. .sp 2
  5275. .NH 2
  5276. Missing
  5277. .sp 1
  5278. .LP
  5279. .XS
  5280. Missing
  5281. .XE
  5282. The \fBset missing\fR command allows you to tell \fBgnuplot\fR what character is
  5283. used in a data file to denote missing data.
  5284.  
  5285. Syntax:
  5286. .br
  5287.       set missing {"<character>"}
  5288. .br
  5289. .br
  5290.       show missing
  5291. .br
  5292.  
  5293. Example:
  5294. .br
  5295.       set missing "?"
  5296. .br
  5297.  
  5298. would mean that, when plotting a file containing
  5299.  
  5300. .br
  5301.          1 1
  5302. .br
  5303. .br
  5304.          2 ?
  5305. .br
  5306. .br
  5307.          3 2
  5308. .br
  5309.  
  5310. the middle line would be ignored.
  5311.  
  5312. There is no default character for \fBmissing\fR.
  5313. .sp 2
  5314. .NH 2
  5315. Multiplot
  5316. .sp 1
  5317. .LP
  5318. .XS
  5319. Multiplot
  5320. .XE
  5321. The command \fBset multiplot\fR places \fBgnuplot\fR in the multiplot mode, in which
  5322. several plots are placed on the same page, window, or screen.
  5323.  
  5324. Syntax:
  5325. .br
  5326.       set multiplot
  5327. .br
  5328. .br
  5329.       set nomultiplot
  5330. .br
  5331.  
  5332. For some terminals, no plot is displayed until the command \fBset nomultiplot\fR
  5333. is given, which causes the entire page to be drawn and then returns \fBgnuplot\fR
  5334. to its normal single-plot mode.  For other terminals, each separate \fBplot\fR
  5335. command produces a plot, but the screen may not be cleared between plots.
  5336.  
  5337. Any labels or arrows that have been defined will be drawn for each plot
  5338. according to the current size and origin (unless their coordinates are
  5339. defined in the \fBscreen\fR system).  Just about everything else that can be
  5340. \fBset\fR is applied to each plot, too.  If you want something to appear only
  5341. once on the page, for instance a single time stamp, you\&'ll need to put a \fBset
  5342. time\fR/\fBset notime\fR pair around one of the \fBplot\fR, \fBsplot\fR or \fBreplot\fR
  5343. commands within the \fBset multiplot\fR/\fBset nomultiplot\fR block.
  5344.  
  5345. The commands \fBset origin\fR and \fBset size\fR must be used to correctly position
  5346. each plot; see \fBset origin\fR and \fBset size\fR for details of their usage.
  5347.  
  5348. Example:
  5349. .br
  5350.       set size 0.7,0.7
  5351. .br
  5352. .br
  5353.       set origin 0.1,0.1
  5354. .br
  5355. .br
  5356.       set multiplot
  5357. .br
  5358. .br
  5359.       set size 0.4,0.4
  5360. .br
  5361. .br
  5362.       set origin 0.1,0.1
  5363. .br
  5364. .br
  5365.       plot sin(x)
  5366. .br
  5367. .br
  5368.       set size 0.2,0.2
  5369. .br
  5370. .br
  5371.       set origin 0.5,0.5
  5372. .br
  5373. .br
  5374.       plot cos(x)
  5375. .br
  5376. .br
  5377.       set nomultiplot
  5378. .br
  5379.  
  5380. displays a plot of cos(x) stacked above a plot of sin(x).  Note the initial
  5381. \fBset size\fR and \fBset origin\fR.  While these are not always required, their
  5382. inclusion is recommended.  Some terminal drivers require that bounding box
  5383. information be available before any plots can be made, and the form given
  5384. above guarantees that the bounding box will include the entire plot array
  5385. rather than just the bounding box of the first plot.
  5386.  
  5387. \fBset size\fR and \fBset origin\fR refer to the entire plotting area used for each
  5388. plot.  If you want to have the axes themselves line up, you can guarantee
  5389. that the margins are the same size with the \fBset margin\fR commands.  See
  5390. \fBset margin\fR for their use.  Note that the margin settings are absolute,
  5391. in character units, so the appearance of the graph in the remaining space
  5392. will depend on the screen size of the display device, e.g., perhaps quite
  5393. different on a video display and a printer.
  5394. .sp 2
  5395. .NH 2
  5396. Mx2tics
  5397. .sp 1
  5398. .LP
  5399. .XS
  5400. Mx2tics
  5401. .XE
  5402. Minor tic marks along the x2 (top) axis are controlled by \fBset mx2tics\fR.
  5403. Please see \fBset mxtics\fR.
  5404. .sp 2
  5405. .NH 2
  5406. Mxtics
  5407. .sp 1
  5408. .LP
  5409. .XS
  5410. Mxtics
  5411. .XE
  5412. Minor tic marks along the x axis are controlled by \fBset mxtics\fR.  They can be
  5413. turned off with \fBset nomxtics\fR.  Similar commands control minor tics along
  5414. the other axes.
  5415.  
  5416. Syntax:
  5417. .br
  5418.       set mxtics {<freq> | default}
  5419. .br
  5420. .br
  5421.       set nomxtics
  5422. .br
  5423. .br
  5424.       show mxtics
  5425. .br
  5426.  
  5427. The same syntax applies to \fBmytics\fR, \fBmztics\fR, \fBmx2tics\fR and \fBmy2tics\fR.
  5428.  
  5429. <freq> is the number of sub-intervals (NOT the number of minor tics) between
  5430. major tics (ten is the default for a linear axis, so there are nine minor
  5431. tics between major tics). Selecting \fBdefault\fR will return the number of minor
  5432. ticks to its default value.
  5433.  
  5434. If the axis is logarithmic, the number of sub-intervals will be set to a
  5435. reasonable number by default (based upon the length of a decade).  This will
  5436. be overridden if <freq> is given.  However the usual minor tics (2, 3, ...,
  5437. 8, 9 between 1 and 10, for example) are obtained by setting <freq> to 10,
  5438. even though there are but nine sub-intervals.
  5439.  
  5440. Minor tics can be used only with uniformly spaced major tics.  Since major
  5441. tics can be placed arbitrarily by \fBset {x|x2|y|y2|z}tics\fR, minor tics cannot
  5442. be used if major tics are explicitly \fBset\fR.
  5443.  
  5444. By default, minor tics are off for linear axes and on for logarithmic axes.
  5445. They inherit the settings for \fBaxis|border\fR and \fB{no}mirror\fR specified for
  5446. the major tics.  Please see \fBset xtics\fR for information about these.
  5447. .sp 2
  5448. .NH 2
  5449. My2tics
  5450. .sp 1
  5451. .LP
  5452. .XS
  5453. My2tics
  5454. .XE
  5455. Minor tic marks along the y2 (right-hand) axis are controlled by \fBset
  5456. my2tics\fR.  Please see \fBset mxtics\fR.
  5457. .sp 2
  5458. .NH 2
  5459. Mytics
  5460. .sp 1
  5461. .LP
  5462. .XS
  5463. Mytics
  5464. .XE
  5465. Minor tic marks along the y axis are controlled by \fBset mytics\fR.  Please
  5466. see \fBset mxtics\fR.
  5467. .sp 2
  5468. .NH 2
  5469. Mztics
  5470. .sp 1
  5471. .LP
  5472. .XS
  5473. Mztics
  5474. .XE
  5475. Minor tic marks along the z axis are controlled by \fBset mztics\fR.  Please
  5476. see \fBset mxtics\fR.
  5477. .sp 2
  5478. .NH 2
  5479. Offsets
  5480. .sp 1
  5481. .LP
  5482. .XS
  5483. Offsets
  5484. .XE
  5485. Offsets provide a mechanism to put a boundary around the data inside of an
  5486. autoscaled graph.
  5487.  
  5488. Syntax:
  5489. .br
  5490.       set offsets <left>, <right>, <top>, <bottom>
  5491. .br
  5492. .br
  5493.       set nooffsets
  5494. .br
  5495. .br
  5496.       show offsets
  5497. .br
  5498.  
  5499. Each offset may be a constant or an expression.  Each defaults to 0.  Left
  5500. and right offsets are given in units of the x axis, top and bottom offsets in
  5501. units of the y axis.  A positive offset expands the graph in the specified
  5502. direction, e.g., a positive bottom offset makes ymin more negative.  Negative
  5503. offsets, while permitted, can have unexpected interactions with autoscaling
  5504. and clipping.
  5505.  
  5506. Offsets are ignored in \fBsplot\fRs.
  5507.  
  5508. Example:
  5509. .br
  5510.       set offsets 0, 0, 2, 2
  5511. .br
  5512. .br
  5513.       plot sin(x)
  5514. .br
  5515.  
  5516. This graph of sin(x) will have a y range [-3:3] because the function
  5517. will be autoscaled to [-1:1] and the vertical offsets are each two.
  5518. .sp 2
  5519. .NH 2
  5520. Origin
  5521. .sp 1
  5522. .LP
  5523. .XS
  5524. Origin
  5525. .XE
  5526. The \fBset origin\fR command is used to specify the origin of a plotting surface
  5527. (i.e., the graph and its margins) on the screen.  The coordinates are given
  5528. in the \fBscreen\fR coordinate system (see \fBcoordinates\fR for information about
  5529. this system).
  5530.  
  5531. Syntax:
  5532. .br
  5533.       set origin <x-origin>,<y-origin>
  5534. .br
  5535. .sp 2
  5536. .NH 2
  5537. Output
  5538. .sp 1
  5539. .LP
  5540. .XS
  5541. Output
  5542. .XE
  5543. By default, screens are displayed to the standard output. The \fBset output\fR
  5544. command redirects the display to the specified file or device.
  5545.  
  5546. Syntax:
  5547. .br
  5548.       set output {"<filename>"}
  5549. .br
  5550. .br
  5551.       show output
  5552. .br
  5553.  
  5554. The filename must be enclosed in quotes.  If the filename is omitted, any
  5555. output file opened by a previous invocation of \fBset output\fR will be closed
  5556. and new output will be sent to STDOUT.  (If you give the command \fBset output
  5557. "STDOUT"\fR, your output may be sent to a file named "STDOUT"!  ["May be", not
  5558. "will be", because some terminals, like \fBx11\fR, ignore \fBset output\fR.])
  5559.  
  5560. MSDOS users should note that the \\ character has special significance in
  5561. double-quoted strings, so single-quotes should be used for filenames in
  5562. different directories.
  5563.  
  5564. When both \fBset terminal\fR and \fBset output\fR are used together, it is safest to
  5565. give \fBset terminal\fR first, because some terminals set a flag which is needed
  5566. in some operating systems.  This would be the case, for example, if the
  5567. operating system needs to know whether or not a file is to be formatted in
  5568. order to open it properly.
  5569.  
  5570. On machines with popen functions (Unix), output can be piped through a shell
  5571. command if the first non-whitespace character of the filename is \&'|\&'.
  5572. For instance,
  5573.  
  5574. .br
  5575.       set output "|lpr -Plaser filename"
  5576. .br
  5577. .br
  5578.       set output "|lp -dlaser filename"
  5579. .br
  5580.  
  5581. On MSDOS machines, \fBset output "PRN"\fR will direct the output to the default
  5582. printer.  On VMS, output can be sent directly to any spooled device.  It is
  5583. also possible to send the output to DECnet transparent tasks, which allows
  5584. some flexibility.
  5585. .sp 2
  5586. .NH 2
  5587. Parametric
  5588. .sp 1
  5589. .LP
  5590. .XS
  5591. Parametric
  5592. .XE
  5593. The \fBset parametric\fR command changes the meaning of \fBplot\fR (\fBsplot\fR) from
  5594. normal functions to parametric functions.  The command \fBset noparametric\fR
  5595. restores the plotting style to normal, single-valued expression plotting.
  5596.  
  5597. Syntax:
  5598. .br
  5599.       set parametric
  5600. .br
  5601. .br
  5602.       set noparametric
  5603. .br
  5604. .br
  5605.       show parametric
  5606. .br
  5607.  
  5608. For 2-d plotting, a parametric function is determined by a pair of parametric
  5609. functions operating on a parameter.  An example of a 2-d parametric function
  5610. would be \fBplot sin(t),cos(t)\fR, which draws a circle (if the aspect ratio is
  5611. set correctly---see \fBset size\fR).  \fBgnuplot\fR will display an error message if
  5612. both functions are not provided for a parametric \fBplot\fR.
  5613.  
  5614. For 3-d plotting, the surface is described as x=f(u,v), y=g(u,v), z=h(u,v).
  5615. Therefore a triplet of functions is required.  An example of a 3-d parametric
  5616. function would be \fBcos(u)*cos(v),cos(u)*sin(v),sin(u)\fR, which draws a sphere.
  5617. \fBgnuplot\fR will display an error message if all three functions are not
  5618. provided for a parametric \fBsplot\fR.
  5619.  
  5620. The total set of possible plots is a superset of the simple f(x) style plots,
  5621. since the two functions can describe the x and y values to be computed
  5622. separately.  In fact, plots of the type t,f(t) are equivalent to those
  5623. produced with f(x) because the x values are computed using the identity
  5624. function.  Similarly, 3-d plots of the type u,v,f(u,v) are equivalent to
  5625. f(x,y).
  5626.  
  5627. Note that the order the parametric functions are specified is xfunction,
  5628. yfunction (and zfunction) and that each operates over the common parametric
  5629. domain.
  5630.  
  5631. Also, the \fBset parametric\fR function implies a new range of values.  Whereas
  5632. the normal f(x) and f(x,y) style plotting assume an xrange and yrange (and
  5633. zrange), the parametric mode additionally specifies a trange, urange, and
  5634. vrange.  These ranges may be set directly with \fBset trange\fR, \fBset urange\fR,
  5635. and \fBset vrange\fR, or by specifying the range on the \fBplot\fR or \fBsplot\fR
  5636. commands.  Currently the default range for these parametric variables is
  5637. [-5:5].  Setting the ranges to something more meaningful is expected.
  5638. .sp 2
  5639. .NH 2
  5640. Pointsize
  5641. .sp 1
  5642. .LP
  5643. .XS
  5644. Pointsize
  5645. .XE
  5646. The \fBset pointsize\fR command scales the size of the points used in plots.
  5647.  
  5648. Syntax:
  5649. .br
  5650.       set pointsize <multiplier>
  5651. .br
  5652. .br
  5653.       show pointsize
  5654. .br
  5655.  
  5656. The default is a multiplier of 1.0.  Larger pointsizes may be useful to
  5657. make points more visible in bitmapped graphics.
  5658.  
  5659. The pointsize of a single plot may be changed on the \fBplot\fR command.  See
  5660. \fBplot with\fR for details.
  5661.  
  5662. Please note that the pointsize setting is not supported by all terminal
  5663. types.
  5664. .sp 2
  5665. .NH 2
  5666. Polar
  5667. .sp 1
  5668. .LP
  5669. .XS
  5670. Polar
  5671. .XE
  5672. The \fBset polar\fR command changes the meaning of the plot from rectangular
  5673. coordinates to polar coordinates.
  5674.  
  5675. Syntax:
  5676. .br
  5677.       set polar
  5678. .br
  5679. .br
  5680.       set nopolar
  5681. .br
  5682. .br
  5683.       show polar
  5684. .br
  5685.  
  5686. There have been changes made to polar mode in version 3.7, so that scripts
  5687. for \fBgnuplot\fR versions 3.5 and earlier will require modification.  The main
  5688. change is that the dummy variable t is used for the angle so that the x and
  5689. y ranges can be controlled independently.  Other changes are:
  5690. 1) tics are no longer put along the zero axes automatically
  5691. ---use \fBset xtics axis nomirror\fR; \fBset ytics axis nomirror\fR;
  5692. 2) the grid, if selected, is not automatically polar
  5693. ---use \fBset grid polar\fR;
  5694. 3) the grid is not labelled with angles
  5695. ---use \fBset label\fR as necessary.
  5696.  
  5697. In polar coordinates, the dummy variable (t) is an angle.  The default range
  5698. of t is [0:2*pi], or, if degree units have been selected, to [0:360] (see
  5699. \fBset angles\fR).
  5700.  
  5701. The command \fBset nopolar\fR changes the meaning of the plot back to the default
  5702. rectangular coordinate system.
  5703.  
  5704. The \fBset polar\fR command is not supported for \fBsplot\fRs.  See the \fBset mapping\fR
  5705. command for similar functionality for \fBsplot\fRs.
  5706.  
  5707. While in polar coordinates the meaning of an expression in t is really
  5708. r = f(t), where t is an angle of rotation.  The trange controls the domain
  5709. (the angle) of the function, and the x and y ranges control the range of the
  5710. graph in the x and y directions.  Each of these ranges, as well as the
  5711. rrange, may be autoscaled or set explicitly.  See \fBset xrange\fR for details
  5712. of all the \fBset range\fR commands.
  5713.  
  5714. Example:
  5715. .br
  5716.       set polar
  5717. .br
  5718. .br
  5719.       plot t*sin(t)
  5720. .br
  5721. .br
  5722.       plot [-2*pi:2*pi] [-3:3] [-3:3] t*sin(t)
  5723. .br
  5724.  
  5725. The first \fBplot\fR uses the default polar angular domain of 0 to 2*pi.  The
  5726. radius and the size of the graph are scaled automatically.  The second \fBplot\fR
  5727. expands the domain, and restricts the size of the graph to [-3:3] in both
  5728. directions.
  5729.  
  5730. You may want to \fBset size square\fR to have \fBgnuplot\fR try to make the aspect
  5731. ratio equal to unity, so that circles look circular.
  5732. .sp 2
  5733. .NH 2
  5734. Rmargin
  5735. .sp 1
  5736. .LP
  5737. .XS
  5738. Rmargin
  5739. .XE
  5740. The command \fBset rmargin\fR sets the size of the right margin.  Please see
  5741. \fBset margin\fR for details.
  5742. .sp 2
  5743. .NH 2
  5744. Rrange
  5745. .sp 1
  5746. .LP
  5747. .XS
  5748. Rrange
  5749. .XE
  5750. The \fBset rrange\fR command sets the range of the radial coordinate for a
  5751. graph in polar mode.  Please see \fBset xrange\fR for details.
  5752. .sp 2
  5753. .NH 2
  5754. Samples
  5755. .sp 1
  5756. .LP
  5757. .XS
  5758. Samples
  5759. .XE
  5760. The sampling rate of functions, or for interpolating data, may be changed
  5761. by the \fBset samples\fR command.
  5762.  
  5763. Syntax:
  5764. .br
  5765.       set samples <samples_1> {,<samples_2>}
  5766. .br
  5767. .br
  5768.       show samples
  5769. .br
  5770.  
  5771. By default, sampling is set to 100 points.  A higher sampling rate will
  5772. produce more accurate plots, but will take longer.  This parameter has no
  5773. effect on data file plotting unless one of the interpolation/approximation
  5774. options is used.  See \fBplot smooth\fR re 2-d data and \fBset cntrparam\fR and
  5775. \fBset dgrid3d\fR re 3-d data.
  5776.  
  5777. When a 2-d graph is being done, only the value of <samples_1> is relevant.
  5778.  
  5779. When a surface plot is being done without the removal of hidden lines, the
  5780. value of samples specifies the number of samples that are to be evaluated for
  5781. the isolines.  Each iso-v line will have <sample_1> samples and each iso-u
  5782. line will have <sample_2> samples.  If you only specify <samples_1>,
  5783. <samples_2> will be set to the same value as <samples_1>.  See also \fBset
  5784. isosamples\fR.
  5785. .sp 2
  5786. .NH 2
  5787. Size
  5788. .sp 1
  5789. .LP
  5790. .XS
  5791. Size
  5792. .XE
  5793. The \fBset size\fR command scales the displayed size of the plot.
  5794.  
  5795. Syntax:
  5796. .br
  5797.       set size {{no}square | ratio <r> | noratio} {<xscale>,<yscale>}
  5798. .br
  5799. .br
  5800.       show size
  5801. .br
  5802.  
  5803. The <xscale> and <yscale> values are the scaling factors for the size of the
  5804. plot, which includes the graph and the margins.
  5805.  
  5806. \fBratio\fR causes \fBgnuplot\fR to try to create a graph with an aspect ratio of <r>
  5807. (the ratio of the y-axis length to the x-axis length) within the portion of
  5808. the plot specified by <xscale> and <yscale>.
  5809.  
  5810. The meaning of a negative value for <r> is different.  If <r>=-1, gnuplot
  5811. tries to set the scales so that the unit has the same length on both the x
  5812. and y axes (suitable for geographical data, for instance).  If <r>=-2, the
  5813. unit on y has twice the length of the unit on x, and so on.
  5814.  
  5815. The success of \fBgnuplot\fR in producing the requested aspect ratio depends on
  5816. the terminal selected.  The graph area will be the largest rectangle of
  5817. aspect ratio <r> that will fit into the specified portion of the output
  5818. (leaving adequate margins, of course).
  5819.  
  5820. \fBsquare\fR is a synonym for \fBratio 1\fR.
  5821.  
  5822. Both \fBnoratio\fR and \fBnosquare\fR return the graph to the default aspect ratio
  5823. of the terminal, but do not return <xscale> or <yscale> to their default
  5824. values (1.0).
  5825.  
  5826. \fBratio\fR and \fBsquare\fR have no effect on 3-d plots.
  5827.  
  5828. \fBset size\fR is relative to the default size, which differs from terminal to
  5829. terminal.  Since \fBgnuplot\fR fills as much of the available plotting area as
  5830. possible by default, it is safer to use \fBset size\fR to decrease the size of
  5831. a plot than to increase it.  See \fBset terminal\fR for the default sizes.
  5832.  
  5833. On some terminals, changing the size of the plot will result in text being
  5834. misplaced.
  5835.  
  5836. Examples:
  5837.  
  5838. To set the size to normal size use:
  5839. .br
  5840.       set size 1,1
  5841. .br
  5842.  
  5843. To make the graph half size and square use:
  5844. .br
  5845.       set size square 0.5,0.5
  5846. .br
  5847.  
  5848. To make the graph twice as high as wide use:
  5849. .br
  5850.       set size ratio 2
  5851. .br
  5852.  
  5853. .sp 2
  5854. .NH 2
  5855. Style
  5856. .sp 1
  5857. .LP
  5858. .XS
  5859. Style
  5860. .XE
  5861. Default styles are chosen with the \fBset function style\fR and \fBset data style\fR
  5862. commands.  See \fBplot with\fR for information about how to override the default
  5863. plotting style for individual functions and data sets.
  5864.  
  5865. Syntax:
  5866. .br
  5867.       set function style <style>
  5868. .br
  5869. .br
  5870.       set data style <style>
  5871. .br
  5872. .br
  5873.       show function style
  5874. .br
  5875. .br
  5876.       show data style
  5877. .br
  5878.  
  5879. The types used for all line and point styles (i.e., solid, dash-dot, color,
  5880. etc. for lines; circles, squares, crosses, etc. for points) will be either
  5881. those specified on the \fBplot\fR or \fBsplot\fR command or will be chosen
  5882. sequentially from the types available to the terminal in use.  Use the
  5883. command \fBtest\fR to see what is available.
  5884.  
  5885. None of the styles requiring more than two columns of information (e.g.,
  5886. \fBerrorbars\fR) can be used with \fBsplot\fRs or function \fBplot\fRs.  Neither \fBboxes\fR
  5887. nor any of the \fBsteps\fR styles can be used with \fBsplot\fRs.  If an inappropriate
  5888. style is specified, it will be changed to \fBpoints\fR.
  5889.  
  5890. For 2-d data with more than two columns, \fBgnuplot\fR is picky about the allowed
  5891. \fBerrorbar\fR styles.  The \fBusing\fR option on the \fBplot\fR command can be used to
  5892. set up the correct columns for the style you want.  (In this discussion,
  5893. "column" will be used to refer both to a column in the data file and an entry
  5894. in the \fBusing\fR list.)
  5895.  
  5896. For three columns, only \fBxerrorbars\fR, \fByerrorbars\fR (or \fBerrorbars\fR), \fBboxes\fR,
  5897. and \fBboxerrorbars\fR are allowed.  If another plot style is used, the style
  5898. will be changed to \fByerrorbars\fR.  The \fBboxerrorbars\fR style will calculate the
  5899. boxwidth automatically.
  5900.  
  5901. For four columns, only \fBxerrorbars\fR, \fByerrorbars\fR (or \fBerrorbars\fR),
  5902. \fBxyerrorbars\fR, \fBboxxyerrorbars\fR, and \fBboxerrorbars\fR are allowed.  An illegal
  5903. style will be changed to \fByerrorbars\fR.
  5904.  
  5905. Five-column data allow only the \fBboxerrorbars\fR, \fBfinancebars\fR, and
  5906. \fBcandlesticks\fR styles.  (The last two of these are primarily used for plots
  5907. of financial prices.)  An illegal style will be changed to \fBboxerrorbars\fR
  5908. before plotting.
  5909.  
  5910. Six- and seven-column data only allow the \fBxyerrorbars\fR and \fBboxxyerrorbars\fR
  5911. styles.  Illegal styles will be changed to \fBxyerrorbars\fR before plotting.
  5912.  
  5913. For more information about error bars, please see \fBplot errorbars\fR.
  5914. .sp 2
  5915. .RS
  5916. .IP
  5917. .NH 3
  5918. Boxerrorbars
  5919. .sp 1
  5920. .LP
  5921. .XS
  5922. Boxerrorbars
  5923. .XE
  5924. The \fBboxerrorbars\fR style is only relevant to 2-d data plotting.  It is a
  5925. combination of the \fBboxes\fR and \fByerrorbars\fR styles.  The boxwidth will come
  5926. from the fourth column if the y errors are in the form of "ydelta" and the
  5927. boxwidth was not previously set equal to -2.0 (\fBset boxwidth -2.0\fR) or from
  5928. the fifth column if the y errors are in the form of "ylow yhigh".  The
  5929. special case  \fBboxwidth = -2.0\fR is for four-column data with y errors in the
  5930. form "ylow yhigh".  In this case the boxwidth will be calculated so that each
  5931. box touches the adjacent boxes.  The width will also be calculated in cases
  5932. where three-column data are used.
  5933.  
  5934. The box height is determined from the y error in the same way as it is for
  5935. the \fByerrorbars\fR style---either from y-ydelta to y+ydelta or from ylow to
  5936. yhigh, depending on how many data columns are provided.
  5937. .sp 2
  5938. .NH 3
  5939. Boxes
  5940. .sp 1
  5941. .LP
  5942. .XS
  5943. Boxes
  5944. .XE
  5945. The \fBboxes\fR style is only relevant to 2-d plotting.  It draws a box centered
  5946. about the given x coordinate from the x axis (not the graph border) to the
  5947. given y coordinate.  The width of the box is obtained in one of three ways.
  5948. If it is a data plot and the data file has a third column, this will be used
  5949. to set the width of the box.  If not, if a width has been set using the \fBset
  5950. boxwidth\fR command, this will be used.  If neither of these is available, the
  5951. width of each box will be calculated automatically so that it touches the
  5952. adjacent boxes.
  5953. .sp 2
  5954. .NH 3
  5955. Boxxyerrorbars
  5956. .sp 1
  5957. .LP
  5958. .XS
  5959. Boxxyerrorbars
  5960. .XE
  5961. The \fBboxxyerrorbars\fR style is only relevant to 2-d data plotting.  It is a
  5962. combination of the \fBboxes\fR and \fBxyerrorbars\fR styles.
  5963.  
  5964. The box width and height are determined from the x and y errors in the same
  5965. way as they are for the \fBxyerrorbars\fR style---either from xlow to xhigh and
  5966. from ylow to yhigh, or from x-xdelta to x+xdelta and from y-ydelta to
  5967. y+ydelta , depending on how many data columns are provided.
  5968. .sp 2
  5969. .NH 3
  5970. Candlesticks
  5971. .sp 1
  5972. .LP
  5973. .XS
  5974. Candlesticks
  5975. .XE
  5976. The \fBcandlesticks\fR style is only relevant for 2-d data plotting of financial
  5977. data.  Five columns of data are required; in order, these should be the x
  5978. coordinate (most likely a date) and the opening, low, high, and closing
  5979. prices.  The symbol is an open rectangle, centered horizontally at the x
  5980. coordinate and limited vertically by the opening and closing prices.  A
  5981. vertical line segment at the x coordinate extends up from the top of the
  5982. rectangle to the high price and another down to the low.  The width of the
  5983. rectangle may be changed by \fBset bar\fR.  The symbol will be unchanged if the
  5984. low and high prices are interchanged or if the opening and closing prices
  5985. are interchanged.  See \fBset bar\fR and \fBfinancebars\fR.
  5986. .sp 2
  5987. .NH 3
  5988. Dots
  5989. .sp 1
  5990. .LP
  5991. .XS
  5992. Dots
  5993. .XE
  5994. The \fBdots\fR style plots a tiny dot at each point; this is useful for scatter
  5995. plots with many points.
  5996. .sp 2
  5997. .NH 3
  5998. Financebars
  5999. .sp 1
  6000. .LP
  6001. .XS
  6002. Financebars
  6003. .XE
  6004. The \fBfinancebars\fR style is only relevant for 2-d data plotting of financial
  6005. data.  Five columns of data are required; in order, these should be the x
  6006. coordinate (most likely a date) and the opening, low, high, and closing
  6007. prices.  The symbol is a vertical line segment, located horizontally at the x
  6008. coordinate and limited vertically by the high and low prices.  A horizontal
  6009. tic on the left marks the opening price and one on the right marks the
  6010. closing price.  The length of these tics may be changed by \fBset bar\fR.  The
  6011. symbol will be unchanged if the high and low prices are interchanged.  See
  6012. \fBset bar\fR and \fBcandlesticks\fR.
  6013. .sp 2
  6014. .NH 3
  6015. Fsteps
  6016. .sp 1
  6017. .LP
  6018. .XS
  6019. Fsteps
  6020. .XE
  6021. The \fBfsteps\fR style is only relevant to 2-d plotting.  It connects consecutive
  6022. points with two line segments: the first from (x1,y1) to (x1,y2) and the
  6023. second from (x1,y2) to (x2,y2).
  6024. .sp 2
  6025. .NH 3
  6026. Histeps
  6027. .sp 1
  6028. .LP
  6029. .XS
  6030. Histeps
  6031. .XE
  6032. The \fBhisteps\fR style is only relevant to 2-d plotting.  It is intended for
  6033. plotting histograms.  Y-values are assumed to be centered at the x-values;
  6034. the point at x1 is represented as a horizontal line from ((x0+x1)/2,y1) to
  6035. ((x1+x2)/2,y1).  The lines representing the end points are extended so that
  6036. the step is centered on at x.  Adjacent points are connected by a vertical
  6037. line at their average x, that is, from ((x1+x2)/2,y1) to ((x1+x2)/2,y2).
  6038.  
  6039. If \fBautoscale\fR is in effect, it selects the xrange from the data rather than
  6040. the steps, so the end points will appear only half as wide as the others.
  6041.  
  6042. \fBhisteps\fR is only a plotting style; \fBgnuplot\fR does not have the ability to
  6043. create bins and determine their population from some data set.
  6044. .sp 2
  6045. .NH 3
  6046. Impulses
  6047. .sp 1
  6048. .LP
  6049. .XS
  6050. Impulses
  6051. .XE
  6052. The \fBimpulses\fR style displays a vertical line from the x axis (not the graph
  6053. border), or from the grid base for \fBsplot\fR, to each point.
  6054. .sp 2
  6055. .NH 3
  6056. Lines
  6057. .sp 1
  6058. .LP
  6059. .XS
  6060. Lines
  6061. .XE
  6062. The \fBlines\fR style connects adjacent points with straight line segments.
  6063. .sp 2
  6064. .NH 3
  6065. Linespoints
  6066. .sp 1
  6067. .LP
  6068. .XS
  6069. Linespoints
  6070. .XE
  6071. The \fBlinespoints\fR style does both \fBlines\fR and \fBpoints\fR, that is, it draws a
  6072. small symbol at each point and then connects adjacent points with straight
  6073. line segments.  The command \fBset pointsize\fR may be used to change the size of
  6074. the points.  See \fBset pointsize\fR for its usage.
  6075.  
  6076. \fBlinespoints\fR may be abbreviated \fBlp\fR.
  6077. .sp 2
  6078. .NH 3
  6079. Points
  6080. .sp 1
  6081. .LP
  6082. .XS
  6083. Points
  6084. .XE
  6085. The \fBpoints\fR style displays a small symbol at each point.  The command \fBset
  6086. pointsize\fR may be used to change the size of the points.  See \fBset pointsize\fR
  6087. for its usage.
  6088. .sp 2
  6089. .NH 3
  6090. Steps
  6091. .sp 1
  6092. .LP
  6093. .XS
  6094. Steps
  6095. .XE
  6096. The \fBsteps\fR style is only relevant to 2-d plotting.  It connects consecutive
  6097. points with two line segments: the first from (x1,y1) to (x2,y1) and the
  6098. second from (x2,y1) to (x2,y2).
  6099. .sp 2
  6100. .NH 3
  6101. Vector
  6102. .sp 1
  6103. .LP
  6104. .XS
  6105. Vector
  6106. .XE
  6107. The \fBvector\fR style draws a vector from (x,y) to (x+xdelta,y+ydelta).  Thus
  6108. it requires four columns of data.  It also draws a small arrowhead at the
  6109. end of the vector.
  6110.  
  6111. The \fBvector\fR style is still experimental: it doesn\&'t get clipped properly
  6112. and other things may also be wrong with it.  Use it at your own risk.
  6113. .sp 2
  6114. .NH 3
  6115. Xerrorbars
  6116. .sp 1
  6117. .LP
  6118. .XS
  6119. Xerrorbars
  6120. .XE
  6121. The \fBxerrorbars\fR style is only relevant to 2-d data plots.  \fBxerrorbars\fR is
  6122. like \fBdots\fR, except that a horizontal error bar is also drawn.  At each point
  6123. (x,y), a line is drawn from (xlow,y) to (xhigh,y) or from (x-xdelta,y) to
  6124. (x+xdelta,y), depending on how many data columns are provided.  A tic mark
  6125. is placed at the ends of the error bar (unless \fBset bar\fR is used---see \fBset
  6126. bar\fR for details).
  6127. .sp 2
  6128. .NH 3
  6129. Xyerrorbars
  6130. .sp 1
  6131. .LP
  6132. .XS
  6133. Xyerrorbars
  6134. .XE
  6135. The \fBxyerrorbars\fR style is only relevant to 2-d data plots.  \fBxyerrorbars\fR is
  6136. like \fBdots\fR, except that horizontal and vertical error bars are also drawn.
  6137. At each point (x,y), lines are drawn from (x,y-ydelta) to (x,y+ydelta) and
  6138. from (x-xdelta,y) to (x+xdelta,y) or from (x,ylow) to (x,yhigh) and from
  6139. (xlow,y) to (xhigh,y), depending upon the number of data columns provided.  A
  6140. tic mark is placed at the ends of the error bar (unless \fBset bar\fR is
  6141. used---see \fBset bar\fR for details).
  6142.  
  6143. If data are provided in an unsupported mixed form, the \fBusing\fR filter on the
  6144. \fBplot\fR command should be used to set up the appropriate form.  For example,
  6145. if the data are of the form (x,y,xdelta,ylow,yhigh), then you can use
  6146.  
  6147. .br
  6148.       plot 'data' using 1:2:($1-$3),($1+$3),4,5 with xyerrorbars
  6149. .br
  6150. .sp 2
  6151. .NH 3
  6152. Yerrorbars
  6153. .sp 1
  6154. .LP
  6155. .XS
  6156. Yerrorbars
  6157. .XE
  6158. The \fByerrorbars\fR (or \fBerrorbars\fR) style is only relevant to 2-d data plots.
  6159. \fByerrorbars\fR is like \fBdots\fR, except that a vertical error bar is also drawn.
  6160. At each point (x,y), a line is drawn from (x,y-ydelta) to (x,y+ydelta) or
  6161. from (x,ylow) to (x,yhigh), depending on how many data columns are provided.
  6162. A tic mark is placed at the ends of the error bar (unless \fBset bar\fR is
  6163. used---see \fBset bar\fR for details).
  6164. .sp 2
  6165. .RE
  6166. .br
  6167. .NH 2
  6168. Surface
  6169. .sp 1
  6170. .LP
  6171. .XS
  6172. Surface
  6173. .XE
  6174. The command \fBset surface\fR controls the display of surfaces by \fBsplot\fR.
  6175.  
  6176. Syntax:
  6177. .br
  6178.       set surface
  6179. .br
  6180. .br
  6181.       set nosurface
  6182. .br
  6183. .br
  6184.       show surface
  6185. .br
  6186.  
  6187. The surface is drawn with the style specifed by \fBwith\fR, or else the
  6188. appropriate style, data or function.
  6189.  
  6190. Whenever \fBset nosurface\fR is issued, \fBsplot\fR will not draw points or lines
  6191. corresponding to the function or data file points.  Contours may be still be
  6192. drawn on the surface, depending on the \fBset contour\fR option. \fBset nosurface;
  6193. set contour base\fR is useful for displaying contours on the grid base.  See
  6194. also \fBset contour\fR.
  6195. .sp 2
  6196. .NH 2
  6197. Terminal
  6198. .sp 1
  6199. .LP
  6200. .XS
  6201. Terminal
  6202. .XE
  6203. \fBgnuplot\fR supports many different graphics devices.  Use \fBset terminal\fR to
  6204. tell \fBgnuplot\fR what kind of output to generate. Use \fBset output\fR to redirect
  6205. that output to a file or device.
  6206.  
  6207. Syntax:
  6208. .br
  6209.       set terminal {<terminal-type>}
  6210. .br
  6211. .br
  6212.       show terminal
  6213. .br
  6214.  
  6215. If <terminal-type> is omitted, \fBgnuplot\fR will list the available terminal
  6216. types.  <terminal-type> may be abbreviated.
  6217.  
  6218. If both \fBset terminal\fR and \fBset output\fR are used together, it is safest to
  6219. give \fBset terminal\fR first, because some terminals set a flag which is needed
  6220. in some operating systems.
  6221.  
  6222. Several terminals have additional options.  For example, see \fBdumb\fR,
  6223. \fBiris4d\fR, \fBhpljii\fR or \fBpostscript\fR.
  6224.  
  6225. This document may describe drivers that are not available to you because they
  6226. were not installed, or it may not describe all the drivers that are available
  6227. to you, depending on its output format.
  6228. .sp 2
  6229. .RS
  6230. .IP
  6231. .NH 3
  6232. Aed767
  6233. .sp 1
  6234. .LP
  6235. .XS
  6236. Aed767
  6237. .XE
  6238. The \fBaed512\fR and \fBaed767\fR terminal drivers support AED graphics terminals.
  6239. The two drivers differ only in their horizontal ranges, which are 512 and
  6240. 768 pixels, respectively.  Their vertical range is 575 pixels.  There are
  6241. no options for these drivers.
  6242. .sp 2
  6243. .NH 3
  6244. Aifm
  6245. .sp 1
  6246. .LP
  6247. .XS
  6248. Aifm
  6249. .XE
  6250. Several options may be set in \fBaifm\fR---the Adobe Illustrator 3.0+ driver.
  6251.  
  6252. Syntax:
  6253. .br
  6254.       set terminal aifm {<color>} {"<fontname>"} {<fontsize>}
  6255. .br
  6256.  
  6257. <color> is either \fBcolor\fR or \fBmonochrome\fR; "<fontname>" is the name of a
  6258. valid PostScript font; <fontsize> is the size of the font in PostScript
  6259. points, before scaling by the \fBset size\fR command.  Selecting \fBdefault\fR sets
  6260. all options to their default values: \fBmonochrome\fR, "Helvetica", and 14pt.
  6261.  
  6262. Since AI does not really support multiple pages, multiple graphs will be
  6263. drawn directly on top of one another.  However, each graph will be grouped
  6264. individually, making it easy to separate them inside AI (just pick them up
  6265. and move them).
  6266.  
  6267. Examples:
  6268. .br
  6269.       set term aifm
  6270. .br
  6271. .br
  6272.       set term aifm 22
  6273. .br
  6274. .br
  6275.       set size 0.7,1.4; set term aifm color "Times-Roman" 14
  6276. .br
  6277. .sp 2
  6278. .NH 3
  6279. Amiga
  6280. .sp 1
  6281. .LP
  6282. .XS
  6283. Amiga
  6284. .XE
  6285. The \fBamiga\fR terminal, for Commodore Amiga computers, allows the user to
  6286. plot either to a screen (default), or, if Kickstart 3.0 or higher is
  6287. installed, to a window on the current public screen. The font and its size
  6288. can also be selected.
  6289.  
  6290. Syntax:
  6291. .br
  6292.       set terminal amiga {screen | window} {"<fontname>"} {<fontsize>}
  6293. .br
  6294.  
  6295. The default font is 8-point "topaz".
  6296.  
  6297. The screen option uses a virtual screen, so it is possible that the graph
  6298. will be larger than the screen.
  6299. .sp 2
  6300. .NH 3
  6301. Apollo
  6302. .sp 1
  6303. .LP
  6304. .XS
  6305. Apollo
  6306. .XE
  6307. The \fBapollo\fR terminal driver supports the Apollo Graphics Primitive Resource
  6308. with rescaling after window resizing.  It has no options.
  6309.  
  6310. If a fixed-size window is desired, the \fBgpr\fR terminal may be used instead.
  6311. .sp 2
  6312. .NH 3
  6313. Atari ST (via AES)
  6314. .sp 1
  6315. .LP
  6316. .XS
  6317. Atari ST (via AES)
  6318. .XE
  6319. The \fBatari\fR terminal has options to set the character size and the screen
  6320. colors.
  6321.  
  6322. Syntax:
  6323. .br
  6324.       set terminal atari {<fontsize>} {<col0> <col1> ... <col15.}
  6325. .br
  6326.  
  6327. The character size must appear if any colors are to be specified.  Each of
  6328. the (up to 16) colors is given as a three-digit hex number, where the digits
  6329. represent RED, GREEN and BLUE (in that order).  The range of 0--15 is scaled
  6330. to whatever color range the screen actually has.  On a normal ST screen, odd
  6331. and even intensities are the same.
  6332.  
  6333. Examples:
  6334. .br
  6335.       set terminal atari 4    # use small (6x6) font
  6336. .br
  6337. .br
  6338.       set terminal atari 6 0  # set monochrome screen to white on black
  6339. .br
  6340. .br
  6341.       set terminal atari 13 0 fff f00 f0 f ff f0f
  6342. .br
  6343. .br
  6344.                  # set first seven colors to black, white, green, blue,
  6345. .br
  6346. .br
  6347.                  # cyan, purple, and yellow and use large font (8x16).
  6348. .br
  6349.  
  6350. Additionally, if an environment variable GNUCOLORS exists, its contents are
  6351. interpreted as an options string, but an explicit terminal option takes
  6352. precedence.
  6353. .sp 2
  6354. .NH 3
  6355. Atari ST (via VDI)
  6356. .sp 1
  6357. .LP
  6358. .XS
  6359. Atari ST (via VDI)
  6360. .XE
  6361. The \fBvdi\fR terminal is the same as the \fBatari\fR terminal, except that it sends
  6362. output to the screen via the VDI and not into AES-Windows.
  6363.  
  6364. The \fBvdi\fR terminal has options to set the character size and the screen
  6365. colors.
  6366.  
  6367. Syntax:
  6368. .br
  6369.       set terminal vdi {<fontsize>} {<col0> <col1> ... <col15.}
  6370. .br
  6371.  
  6372. The character size must appear if any colors are to be specified.  Each of
  6373. the (up to 16) colors is given as a three-digit hex number, where the digits
  6374. represent RED, GREEN and BLUE (in that order).  The range of 0--15 is scaled
  6375. to whatever color range the screen actually has.  On a normal ST screen, odd
  6376. and even intensities are the same.
  6377.  
  6378. Examples:
  6379. .br
  6380.       set terminal vdi 4    # use small (6x6) font
  6381. .br
  6382. .br
  6383.       set terminal vdi 6 0  # set monochrome screen to white on black
  6384. .br
  6385. .br
  6386.       set terminal vdi 13 0 fff f00 f0 f ff f0f
  6387. .br
  6388. .br
  6389.                  # set first seven colors to black, white, green, blue,
  6390. .br
  6391. .br
  6392.                  # cyan, purple, and yellow and use large font (8x16).
  6393. .br
  6394.  
  6395. Additionally, if an environment variable GNUCOLORS exists, its contents are
  6396. interpreted as an options string, but an explicit terminal option takes
  6397. precedence.
  6398. .sp 2
  6399. .NH 3
  6400. Be
  6401. .sp 1
  6402. .LP
  6403. .XS
  6404. Be
  6405. .XE
  6406. \fBgnuplot\fR provides the \fBbe\fR terminal type for use with X servers.  This
  6407. terminal type is set automatically at startup if the \fBDISPLAY\fR environment
  6408. variable is set, if the \fBTERM\fR environment variable is set to \fBxterm\fR, or
  6409. if the \fB-display\fR command line option is used.
  6410.  
  6411. Syntax:
  6412. .br
  6413.           set terminal be {reset} {<n>}
  6414. .br
  6415.  
  6416. Multiple plot windows are supported: \fBset terminal be <n>\fR directs the
  6417. output to plot window number n.  If n>0, the terminal number will be
  6418. appended to the window title and the icon will be labeled \fBgplt <n>\fR.
  6419. The active window may distinguished by a change in cursor (from default
  6420. to crosshair.)
  6421.  
  6422. Plot windows remain open even when the \fBgnuplot\fR driver is changed to a
  6423. different device.  A plot window can be closed by pressing the letter q
  6424. while that window has input focus, or by choosing \fBclose\fR from a window
  6425. manager menu.  All plot windows can be closed by specifying \fBreset\fR, which
  6426. actually terminates the subprocess which maintains the windows (unless
  6427. \fB-persist\fR was specified).
  6428.  
  6429. Plot windows will automatically be closed at the end of the session
  6430. unless the \fB-persist\fR option was given.
  6431.  
  6432. The size or aspect ratio of a plot may be changed by resizing the \fBgnuplot\fR
  6433. window.
  6434.  
  6435. Linewidths and pointsizes may be changed from within \fBgnuplot\fR with
  6436. \fBset linestyle\fR.
  6437.  
  6438. For terminal type \fBbe\fR, \fBgnuplot\fR accepts (when initialized) the standard
  6439. X Toolkit options and resources such as geometry, font, and name from the
  6440. command line arguments or a configuration file.  See the X(1) man page
  6441. (or its equivalent) for a description of such options.
  6442.  
  6443. A number of other \fBgnuplot\fR options are available for the \fBbe\fR terminal.
  6444. These may be specified either as command-line options when \fBgnuplot\fR is
  6445. invoked or as resources in the configuration file "/.Xdefaults".  They are
  6446. set upon initialization and cannot be altered during a \fBgnuplot\fR session.
  6447. .sp 2
  6448. .RS
  6449. .IP
  6450. .NH 4
  6451. Command-line_options
  6452. .sp 1
  6453. .LP
  6454. .XS
  6455. Command-line_options
  6456. .XE
  6457. In addition to the X Toolkit options, the following options may be specified
  6458. on the command line when starting \fBgnuplot\fR or as resources in your
  6459. ".Xdefaults" file:
  6460.  
  6461. .EQ
  6462. delim $$
  6463. .EN
  6464. .KS
  6465. .TS
  6466. center box tab (@) ;
  6467. c l .
  6468. `-mono`@forces monochrome rendering on color displays.
  6469. `-gray`@requests grayscale rendering on grayscale or color displays.
  6470.            @(Grayscale displays receive monochrome rendering by default.)
  6471. `-clear`@requests that the window be cleared momentarily before a
  6472.                 @new plot is displayed.
  6473. `-tvtwm`@requests that geometry specifications for position of the
  6474.                 @window be made relative to the currently displayed portion
  6475.                 @of the virtual root.
  6476. `-raise`@raise plot window after each plot
  6477. `-noraise`@do not raise plot window after each plot
  6478. `-persist`@plot windows survive after main gnuplot program exits
  6479. .TE
  6480. .KE
  6481. .EQ
  6482. delim off
  6483. .EN
  6484.  
  6485. The options are shown above in their command-line syntax.  When entered as
  6486. resources in ".Xdefaults", they require a different syntax.
  6487.  
  6488. Example:
  6489. .br
  6490.           gnuplot*gray: on
  6491. .br
  6492.  
  6493. \fBgnuplot\fR also provides a command line option (\fB-pointsize <v>\fR) and a
  6494. resource, \fBgnuplot*pointsize: <v>\fR, to control the size of points plotted
  6495. with the \fBpoints\fR plotting style.  The value \fBv\fR is a real number (greater
  6496. than 0 and less than or equal to ten) used as a scaling factor for point
  6497. sizes.  For example, \fB-pointsize 2\fR uses points twice the default size, and
  6498. \fB-pointsize 0.5\fR uses points half the normal size.
  6499. .sp 2
  6500. .NH 4
  6501. Monochome_options
  6502. .sp 1
  6503. .LP
  6504. .XS
  6505. Monochome_options
  6506. .XE
  6507. For monochrome displays, \fBgnuplot\fR does not honor foreground or background
  6508. colors.  The default is black-on-white.  \fB-rv\fR or \fBgnuplot*reverseVideo: on\fR
  6509. requests white-on-black.
  6510.  
  6511. .sp 2
  6512. .NH 4
  6513. Color_resources
  6514. .sp 1
  6515. .LP
  6516. .XS
  6517. Color_resources
  6518. .XE
  6519. For color displays, \fBgnuplot\fR honors the following resources (shown here
  6520. with their default values) or the greyscale resources.  The values may be
  6521. color names as listed in the BE rgb.txt file on your system, hexadecimal
  6522. RGB color specifications (see BE documentation), or a color name followed
  6523. by a comma and an \fBintensity\fR value from 0 to 1.  For example, \fBblue, 0.5\fR
  6524. means a half intensity blue.
  6525.  
  6526. .EQ
  6527. delim $$
  6528. .EN
  6529. .KS
  6530. .TS
  6531. center box tab (@) ;
  6532. c l .
  6533. @gnuplot*background: white
  6534. @gnuplot*textColor: black
  6535. @gnuplot*borderColor: black
  6536. @gnuplot*axisColor: black
  6537. @gnuplot*line1Color: red
  6538. @gnuplot*line2Color: green
  6539. @gnuplot*line3Color: blue
  6540. @gnuplot*line4Color: magenta
  6541. @gnuplot*line5Color: cyan
  6542. @gnuplot*line6Color: sienna
  6543. @gnuplot*line7Color: orange
  6544. @gnuplot*line8Color: coral
  6545. .TE
  6546. .KE
  6547. .EQ
  6548. delim off
  6549. .EN
  6550.  
  6551.  
  6552. The command-line syntax for these is, for example,
  6553.  
  6554. Example:
  6555. .br
  6556.           gnuplot -background coral
  6557. .br
  6558.  
  6559. .sp 2
  6560. .NH 4
  6561. Grayscale_resources
  6562. .sp 1
  6563. .LP
  6564. .XS
  6565. Grayscale_resources
  6566. .XE
  6567. When \fB-gray\fR is selected, \fBgnuplot\fR honors the following resources for
  6568. grayscale or color displays (shown here with their default values).  Note
  6569. that the default background is black.
  6570.  
  6571. .EQ
  6572. delim $$
  6573. .EN
  6574. .KS
  6575. .TS
  6576. center box tab (@) ;
  6577. c l .
  6578. @gnuplot*background: black
  6579. @gnuplot*textGray: white
  6580. @gnuplot*borderGray: gray50
  6581. @gnuplot*axisGray: gray50
  6582. @gnuplot*line1Gray: gray100
  6583. @gnuplot*line2Gray: gray60
  6584. @gnuplot*line3Gray: gray80
  6585. @gnuplot*line4Gray: gray40
  6586. @gnuplot*line5Gray: gray90
  6587. @gnuplot*line6Gray: gray50
  6588. @gnuplot*line7Gray: gray70
  6589. @gnuplot*line8Gray: gray30
  6590. .TE
  6591. .KE
  6592. .EQ
  6593. delim off
  6594. .EN
  6595.  
  6596.  
  6597. .sp 2
  6598. .NH 4
  6599. Line_resources
  6600. .sp 1
  6601. .LP
  6602. .XS
  6603. Line_resources
  6604. .XE
  6605. \fBgnuplot\fR honors the following resources for setting the width (in pixels) of
  6606. plot lines (shown here with their default values.)  0 or 1 means a minimal
  6607. width line of 1 pixel width.  A value of 2 or 3 may improve the appearance of
  6608. some plots.
  6609.  
  6610. .EQ
  6611. delim $$
  6612. .EN
  6613. .KS
  6614. .TS
  6615. center box tab (@) ;
  6616. c l .
  6617. @gnuplot*borderWidth: 2
  6618. @gnuplot*axisWidth: 0
  6619. @gnuplot*line1Width: 0
  6620. @gnuplot*line2Width: 0
  6621. @gnuplot*line3Width: 0
  6622. @gnuplot*line4Width: 0
  6623. @gnuplot*line5Width: 0
  6624. @gnuplot*line6Width: 0
  6625. @gnuplot*line7Width: 0
  6626. @gnuplot*line8Width: 0
  6627. .TE
  6628. .KE
  6629. .EQ
  6630. delim off
  6631. .EN
  6632.  
  6633.  
  6634. \fBgnuplot\fR honors the following resources for setting the dash style used for
  6635. plotting lines.  0 means a solid line.  A two-digit number \fBjk\fR (\fBj\fR and \fBk\fR
  6636. are >= 1  and <= 9) means a dashed line with a repeated pattern of \fBj\fR pixels
  6637. on followed by \fBk\fR pixels off.  For example, \&'16\&' is a "dotted" line with one
  6638. pixel on followed by six pixels off.  More elaborate on/off patterns can be
  6639. specified with a four-digit value.  For example, \&'4441\&' is four on, four off,
  6640. four on, one off.  The default values shown below are for monochrome displays
  6641. or monochrome rendering on color or grayscale displays.  For color displays,
  6642. the default for each is 0 (solid line) except for \fBaxisDashes\fR which defaults
  6643. to a \&'16\&' dotted line.
  6644.  
  6645. .EQ
  6646. delim $$
  6647. .EN
  6648. .KS
  6649. .TS
  6650. center box tab (@) ;
  6651. c l .
  6652. @gnuplot*borderDashes: 0
  6653. @gnuplot*axisDashes: 16
  6654. @gnuplot*line1Dashes: 0
  6655. @gnuplot*line2Dashes: 42
  6656. @gnuplot*line3Dashes: 13
  6657. @gnuplot*line4Dashes: 44
  6658. @gnuplot*line5Dashes: 15
  6659. @gnuplot*line6Dashes: 4441
  6660. @gnuplot*line7Dashes: 42
  6661. @gnuplot*line8Dashes: 13
  6662. .TE
  6663. .KE
  6664. .EQ
  6665. delim off
  6666. .EN
  6667.  
  6668. .sp 2
  6669. .RE
  6670. .br
  6671. .NH 3
  6672. Cgi
  6673. .sp 1
  6674. .LP
  6675. .XS
  6676. Cgi
  6677. .XE
  6678. The \fBcgi\fR and \fBhcgi\fR terminal drivers support SCO CGI drivers.  \fBhcgi\fR is for
  6679. printers; the environment variable CGIPRNT must be set.  \fBcgi\fR may be used
  6680. for either a display or hardcopy; if the environment variable CGIDISP is set,
  6681. then that display is used.  Otherwise CGIPRNT is used.
  6682.  
  6683. These terminals have no options.
  6684. .sp 2
  6685. .NH 3
  6686. Cgm
  6687. .sp 1
  6688. .LP
  6689. .XS
  6690. Cgm
  6691. .XE
  6692. The \fBcgm\fR terminal generates a Computer Graphics Metafile.  This file format
  6693. is a subset of the ANSI X3.122-1986 standard entitled "Computer Graphics -
  6694. Metafile for the Storage and Transfer of Picture Description Information".
  6695. Several options may be set in \fBcgm\fR.
  6696.  
  6697. Syntax:
  6698. .br
  6699.       set terminal cgm {<mode>} {<color>} {<rotation>} {solid | dashed}
  6700. .br
  6701. .br
  6702.                        {width <plot_width>} {linewidth <line_width>}
  6703. .br
  6704. .br
  6705.                        {"<font>"} {<fontsize>}
  6706. .br
  6707.  
  6708. where <mode> is \fBlandscape\fR, \fBportrait\fR, or \fBdefault\fR;
  6709. <color> is either \fBcolor\fR or \fBmonochrome\fR; 
  6710. <rotation> is either \fBrotate\fR or \fBnorotate\fR;
  6711. \fBsolid\fR draws all curves with solid lines, overriding any dashed patterns;
  6712. <plot_width> is the width of the page in points; 
  6713. <line_width> is the line width in points; 
  6714. <font> is the name of a font; and 
  6715. \fB<fontsize>\fR is the size of the font in points.
  6716.  
  6717. By default, \fBcgm\fR uses rotated text for the Y axis label.
  6718.  
  6719. The first six options can be in any order.  Selecting \fBdefault\fR sets all
  6720. options to their default values.
  6721.  
  6722. Examples:
  6723. .br
  6724.       set terminal cgm landscape color rotate dashed width 432 \\
  6725. .br
  6726. .br
  6727.                      linewidth 1  'Arial Bold' 12       # defaults
  6728. .br
  6729. .br
  6730.       set terminal cgm 14 linewidth 2  14  # wider lines & larger font
  6731. .br
  6732. .br
  6733.       set terminal cgm portrait 'Times Roman Italic' 12
  6734. .br
  6735. .br
  6736.       set terminal cgm color solid    # no pesky dashes!
  6737. .br
  6738. .sp 2
  6739. .RS
  6740. .IP
  6741. .NH 4
  6742. Font
  6743. .sp 1
  6744. .LP
  6745. .XS
  6746. Font
  6747. .XE
  6748. The first part of a Computer Graphics Metafile, the metafile description,
  6749. includes a font table.  In the picture body, a font is designated by an
  6750. index into this table.  By default, this terminal generates a table with
  6751. the following fonts:
  6752.  
  6753. .EQ
  6754. delim $$
  6755. .EN
  6756. .KS
  6757. .TS
  6758. center box tab (@) ;
  6759. c c l .
  6760. @@CGM fonts
  6761. _
  6762. @@Arial
  6763. @@Arial Italic
  6764. @@Arial Bold
  6765. @@Arial Bold Italic
  6766. @@Times Roman
  6767. @@Times Roman Italic
  6768. @@Times Roman Bold
  6769. @@Times Roman Bold Italic
  6770. @@Helvetica
  6771. @@Roman
  6772. .TE
  6773. .KE
  6774. .EQ
  6775. delim off
  6776. .EN
  6777.  
  6778. Case is not distinct, but the modifiers must appear in the above order (that
  6779. is, not \&'Arial Italic Bold\&').  \&'Arial Bold\&' is the default font.
  6780.  
  6781. You may also specify a font name which does not appear in the default font
  6782. table.  In that case, a new font table is constructed with the specified
  6783. font as its only entry.  You must ensure that the spelling, capitalization,
  6784. and spacing of the name are appropriate for the application that will read
  6785. the CGM file.
  6786. .sp 2
  6787. .NH 4
  6788. Fontsize
  6789. .sp 1
  6790. .LP
  6791. .XS
  6792. Fontsize
  6793. .XE
  6794. Fonts are scaled assuming the page is 6 inches wide.  If the \fBsize\fR command
  6795. is used to change the aspect ratio of the page or the CGM file is converted
  6796. to a different width (e.g. it is imported into a document in which the
  6797. margins are not 6 inches apart), the resulting font sizes will be different.
  6798. To change the assumed width, use the \fBwidth\fR option.
  6799. .sp 2
  6800. .NH 4
  6801. Linewidth
  6802. .sp 1
  6803. .LP
  6804. .XS
  6805. Linewidth
  6806. .XE
  6807. The \fBlinewidth\fR option sets the width of lines in pt.  The default width is
  6808. 1 pt.  Scaling is affected by the actual width of the page, as discussed
  6809. under the \fBfontsize\fR and \fBwidth\fR options
  6810. .sp 2
  6811. .NH 4
  6812. Rotate
  6813. .sp 1
  6814. .LP
  6815. .XS
  6816. Rotate
  6817. .XE
  6818. The \fBnorotate\fR option may be used to disable text rotation.  For example,
  6819. the CGM input filter for Word for Windows 6.0c can accept rotated text, but
  6820. the DRAW editor within Word cannot.  If you edit a graph (for example, to
  6821. label a curve), all rotated text is restored to horizontal.  The Y axis
  6822. label will then extend beyond the clip boundary.  With \fBnorotate\fR, the Y
  6823. axis label starts in a less attractive location, but the page can be edited
  6824. without damage.  The \fBrotate\fR option confirms the default behavior.
  6825. .sp 2
  6826. .NH 4
  6827. Solid
  6828. .sp 1
  6829. .LP
  6830. .XS
  6831. Solid
  6832. .XE
  6833. The \fBsolid\fR option may be used to disable dashed line styles in the
  6834. plots.  This is useful when color is enabled and the dashing of the lines
  6835. detracts from the appearance of the plot. The \fBdashed\fR option confirms the
  6836. default behavior, which gives a different dash pattern to each curve.
  6837. .sp 2
  6838. .NH 4
  6839. Size
  6840. .sp 1
  6841. .LP
  6842. .XS
  6843. Size
  6844. .XE
  6845. Default size of a CGM page is 32599 units wide and 23457 units high for
  6846. landscape, or 23457 units wide by 32599 units high for portrait.
  6847. .sp 2
  6848. .NH 4
  6849. Width
  6850. .sp 1
  6851. .LP
  6852. .XS
  6853. Width
  6854. .XE
  6855. All distances in the CGM file are in abstract units.  The application that
  6856. reads the file determines the size of the final page.  By default, the width
  6857. of the final page is assumed to be 6 inches (15.24 cm).  This distance is
  6858. used to calculate the correct font size, and may be changed with the \fBwidth\fR
  6859. option.  The keyword should be followed by the width in points.  (Here, a
  6860. point is 1/72 inch, as in PostScript.  This unit is known as a "big point"
  6861. in TeX.)  \fBgnuplot\fR arithmetic can be used to convert from other units, as
  6862. follows:
  6863. .br
  6864.       set terminal cgm width 432            # default
  6865. .br
  6866. .br
  6867.       set terminal cgm width 6*72           # same as above
  6868. .br
  6869. .br
  6870.       set terminal cgm width 10/2.54*72     # 10 cm wide
  6871. .br
  6872. .sp 2
  6873. .NH 4
  6874. Winword6
  6875. .sp 1
  6876. .LP
  6877. .XS
  6878. Winword6
  6879. .XE
  6880. The default font table was chosen to match, where possible, the default font
  6881. assignments made by the Computer Graphics Metafile input filter for
  6882. Microsoft Word 6.0c, although the filter makes available only \&'Arial\&' and
  6883. \&\&'Times Roman\&' fonts and their bold and/or italic variants.  Other fonts such
  6884. as \&'Helvetica\&' and \&'Roman\&' are not available.  If the CGM file includes a
  6885. font table, the filter mostly ignores it.  However, it changes certain font
  6886. assignments so that they disagree with the table.  As a workaround, the
  6887. \fBwinword6\fR option deletes the font table from the CGM file.  In this case,
  6888. the filter makes predictable font assignments.  \&'Arial Bold\&' is correctly
  6889. assigned even with the font table present, which is one reason it was chosen
  6890. as the default.
  6891.  
  6892. \fBwinword6\fR disables the color tables for a similar reason---with the color
  6893. table included, Microsoft Word displays black for color 7.
  6894.  
  6895. Linewidths and pointsizes may be changed with \fBset linestyle\fR.
  6896. .sp 2
  6897. .RE
  6898. .br
  6899. .NH 3
  6900. Corel
  6901. .sp 1
  6902. .LP
  6903. .XS
  6904. Corel
  6905. .XE
  6906. The \fBcorel\fR terminal driver supports CorelDraw.
  6907.  
  6908. Syntax:
  6909. .br
  6910.       set terminal corel {  default
  6911. .br
  6912. .br
  6913.                           | {monochrome | color
  6914. .br
  6915. .br
  6916.                                {<fontname> {"<fontsize>" 
  6917. .br
  6918. .br
  6919.                                   {<xsize> <ysize> {<linewidth> }}}}}
  6920. .br
  6921.  
  6922. where the fontsize and linewidth are specified in points and the sizes in
  6923. inches.  The defaults are monochrome, "SwitzerlandLight", 22, 8.2, 10 and 1.2.
  6924. .sp 2
  6925. .NH 3
  6926. Debug
  6927. .sp 1
  6928. .LP
  6929. .XS
  6930. Debug
  6931. .XE
  6932. This terminal is provided to allow for the debugging of \fBgnuplot\fR.  It is
  6933. likely to be of use only for users who are modifying the source code.
  6934. .sp 2
  6935. .NH 3
  6936. Svga
  6937. .sp 1
  6938. .LP
  6939. .XS
  6940. Svga
  6941. .XE
  6942. The \fBsvga\fR terminal driver supports PCs with SVGA graphics.  It can only be
  6943. be used if it is compiled with DJGPP.  Its only option is the font.
  6944.  
  6945. Syntax:
  6946. .br
  6947.       set terminal svga {"<fontname>"}
  6948. .br
  6949. .sp 2
  6950. .NH 3
  6951. Dumb
  6952. .sp 1
  6953. .LP
  6954. .XS
  6955. Dumb
  6956. .XE
  6957. The \fBdumb\fR terminal driver has an optional size specification and trailing
  6958. linefeed control.
  6959.  
  6960. Syntax:
  6961. .br
  6962.       set terminal dumb {[no]feed} {<xsize> <ysize>}
  6963. .br
  6964.  
  6965. where <xsize> and <ysize> set the size of the dumb terminals. Default is
  6966. 79 by 24. The last newline is printed only if \fBfeed\fR is enabled.
  6967.  
  6968. Examples:
  6969. .br
  6970.       set term dumb nofeed
  6971. .br
  6972. .br
  6973.       set term dumb 79 49 # VGA screen---why would anyone do that?
  6974. .br
  6975. .sp 2
  6976. .NH 3
  6977. Dxf
  6978. .sp 1
  6979. .LP
  6980. .XS
  6981. Dxf
  6982. .XE
  6983. The \fBdxf\fR terminal driver creates pictures that can be imported into AutoCad
  6984. (Release 10.x).  It has no options of its own, but some features of its plots
  6985. may be modified by other means.  The default size is 120x80 AutoCad units,
  6986. which can be changed by \fBset size\fR.  \fBdxf\fR uses seven colors (white, red,
  6987. yellow, green, cyan, blue and magenta), which can be changed only by
  6988. modifying the source file.  If a black-and-white plotting device is used, the
  6989. colors are mapped to differing line thicknesses.  See the description of the
  6990. AutoCad print/plot command.
  6991. .sp 2
  6992. .NH 3
  6993. Dxy800a
  6994. .sp 1
  6995. .LP
  6996. .XS
  6997. Dxy800a
  6998. .XE
  6999. This terminal driver supports the Roland DXY800A plotter.  It has no options.
  7000. .sp 2
  7001. .NH 3
  7002. Eepic
  7003. .sp 1
  7004. .LP
  7005. .XS
  7006. Eepic
  7007. .XE
  7008. The \fBeepic\fR terminal driver supports the extended LaTeX picture environment.
  7009. It is an alternative to the \fBlatex\fR driver.
  7010.  
  7011. The output of this terminal is intended for use with the "eepic.sty" macro
  7012. package for LaTeX.  To use it, you need "eepic.sty", "epic.sty" and a
  7013. printer driver that supports the "tpic" \\specials.  If your printer driver
  7014. doesn\&'t support those \\specials, "eepicemu.sty" will enable you to use some
  7015. of them.
  7016.  
  7017. Although dotted and dashed lines are possible with \fBeepic\fR and are tempting,
  7018. they do not work well for high-sample-rate curves, fusing the dashes all
  7019. together into a solid line.  For now, the \fBeepic\fR driver creates only solid
  7020. lines.  There is another gnuplot driver (\fBtpic\fR) that supports dashed lines,
  7021. but it cannot be used if your DVI driver doesn\&'t support "tpic" \\specials.
  7022.  
  7023. All drivers for LaTeX offer a special way of controlling text positioning:
  7024. If any text string begins with \&'{\&', you also need to include a \&'}\&' at the
  7025. end of the text, and the whole text will be centered both horizontally
  7026. and vertically by LaTeX. --- If the text string begins with \&'[\&', you need
  7027. to continue it with: a position specification (up to two out of t,b,l,r),
  7028. \&\&']{\&', the text itself, and finally, \&'}\&'. The text itself may be anything
  7029. LaTeX can typeset as an LR-box. \\rule{}{}\&'s may help for best positioning.
  7030.  
  7031. The \fBeepic\fR terminal has no options.
  7032.  
  7033. Examples:
  7034. About label positioning:
  7035. Use gnuplot defaults (mostly sensible, but sometimes not really best):
  7036. .br
  7037.        set title '\\LaTeX\\ -- $ \\gamma $'
  7038. .br
  7039. Force centering both horizontally and vertically:
  7040. .br
  7041.        set label '{\\LaTeX\\ -- $ \\gamma $}' at 0,0
  7042. .br
  7043. Specify own positioning (top here):
  7044. .br
  7045.        set xlabel '[t]{\\LaTeX\\ -- $ \\gamma $}'
  7046. .br
  7047. The other label -- account for long ticlabels:
  7048. .br
  7049.        set ylabel '[r]{\\LaTeX\\ -- $ \\gamma $\\rule{7mm}{0pt}'
  7050. .br
  7051. .sp 2
  7052. .NH 3
  7053. Emxvga
  7054. .sp 1
  7055. .LP
  7056. .XS
  7057. Emxvga
  7058. .XE
  7059. The \fBemxvga\fR, \fBemxvesa\fR and \fBvgal\fR terminal drivers support PCs with SVGA,
  7060. vesa SVGA and VGA graphics boards, respectively.  They are intended to be
  7061. compiled with "emx-gcc" under either DOS or OS/2.  They also need VESA and
  7062. SVGAKIT maintained by Johannes Martin (JMARTIN@GOOFY.ZDV.UNI-MAINZ.DE) with
  7063. additions by David J. Liu (liu@phri.nyu.edu).
  7064.  
  7065. Syntax:
  7066. .br
  7067.       set terminal emxvga
  7068. .br
  7069. .br
  7070.       set terminal emxvesa {vesa-mode}
  7071. .br
  7072. .br
  7073.       set terminal vgal
  7074. .br
  7075.  
  7076. The only option is the vesa mode for \fBemxvesa\fR, which defaults to G640x480x256.
  7077. .sp 2
  7078. .NH 3
  7079. Epson-180dpi
  7080. .sp 1
  7081. .LP
  7082. .XS
  7083. Epson-180dpi
  7084. .XE
  7085. This driver supports a family of Epson printers and derivatives.
  7086.  
  7087. \fBepson-180dpi\fR and \fBepson-60dpi\fR are drivers for Epson LQ-style 24-pin
  7088. printers with resolutions of 180 and 60 dots per inch, respectively.
  7089.  
  7090. \fBepson-lx800\fR is a generic 9-pin driver appropriate for printers like the
  7091. Epson LX-800, the Star NL-10 and NX-1000, the PROPRINTER, and so forth.
  7092.  
  7093. \fBnec-cp6\fR is generix 24-pin driver that can be used for printers like the
  7094. NEC CP6 and the Epson LQ-800.
  7095.  
  7096. The \fBokidata\fR driver supports the 9-pin OKIDATA 320/321 Standard printers.
  7097.  
  7098. The \fBstarc\fR driver is for the Star Color Printer.
  7099.  
  7100. The \fBtandy-60dpi\fR driver is for the Tandy DMP-130 series of 9-pin, 60-dpi
  7101. printers.
  7102.  
  7103. Only \fBnec-cp6\fR has any options.
  7104.  
  7105. Syntax:
  7106. .br
  7107.       set terminal nec-cp6 {monochrome | colour | draft}
  7108. .br
  7109.  
  7110. which defaults to monochrome.
  7111.  
  7112. With each of these drivers, a binary copy is required on a PC to print.  Do
  7113. not use \fBprint\fR---use instead \fBcopy file /b lpt1:\fR.
  7114. .sp 2
  7115. .NH 3
  7116. Excl
  7117. .sp 1
  7118. .LP
  7119. .XS
  7120. Excl
  7121. .XE
  7122. The \fBexcl\fR terminal driver supports Talaris printers such as the EXCL Laser
  7123. printer and the 1590.  It has no options.
  7124. .sp 2
  7125. .NH 3
  7126. Hercules
  7127. .sp 1
  7128. .LP
  7129. .XS
  7130. Hercules
  7131. .XE
  7132. These drivers supports PC monitors with autodetected graphics boards.  They
  7133. can be used only when compiled with Zortech C/C++.  None have options.
  7134. .sp 2
  7135. .NH 3
  7136. Fig
  7137. .sp 1
  7138. .LP
  7139. .XS
  7140. Fig
  7141. .XE
  7142. The \fBfig\fR terminal device generates output in the Fig graphics language.
  7143.  
  7144. Syntax:
  7145. .br
  7146.       set terminal fig {monochrome | color} {small | big}
  7147. .br
  7148. .br
  7149.                        {pointsmax <max_points>}
  7150. .br
  7151. .br
  7152.                        {landscape | portrait}
  7153. .br
  7154. .br
  7155.                        {metric | inches}
  7156. .br
  7157. .br
  7158.                        {fontsize <fsize>}
  7159. .br
  7160. .br
  7161.                        {size <xsize> <ysize>}
  7162. .br
  7163. .br
  7164.                        {thickness <units>}
  7165. .br
  7166. .br
  7167.                        {depth <layer>}
  7168. .br
  7169.  
  7170. \fBmonochrome\fR and \fBcolor\fR determine whether the picture is black-and-white or
  7171. \fBcolor\fR.  \fBsmall\fR and \fBbig\fR produce a 5x3 or 8x5 inch graph in the default
  7172. \fBlandscape\fR mode and 3x5 or 5x8 inches in \fBportrait\fR mode.  <max_points>
  7173. sets the maximum number of points per polyline.  Default units for editing
  7174. with "xfig" may be \fBmetric\fR or \fBinches\fR.  \fBfontsize\fR sets the size of the
  7175. text font to <fsize> points.  \fBsize\fR sets (overrides) the size of the drawing
  7176. area to <xsize>*<ysize> in units of inches or centimeters depending on the
  7177. \fBinches\fR or \fBmetric\fR setting in effect.  \fBdepth\fR sets the default depth layer
  7178. for all lines and text.  The default depth is 10 to leave room for adding
  7179. material with "xfig" on top of the plot.
  7180.  
  7181. \fBthickness\fR sets the default line thickness, which is 1 if not specified.
  7182. Overriding the thickness can be achieved by adding a multiple of 100 to the
  7183. to the \fBlinetype\fR value for a \fBplot\fR command.  In a similar way the \fBdepth\fR
  7184. of plot elements (with respect to the default depth) can be controlled by
  7185. adding a multiple of 1000 to <linetype>.  The depth is then <layer> +
  7186. <linetype>/1000 and the thickness is (<linetype>%1000)/100 or, if that is
  7187. zero, the default line thickness.
  7188.  
  7189. Additional point-plot symbols are also available with the \fBfig\fR driver. The
  7190. symbols can be used through \fBpointtype\fR values % 100 above 50, with different
  7191. fill intensities controlled by <pointtype> % 5 and outlines in black (for
  7192. <pointtype> % 10 < 5) or in the current color.  Available symbols are
  7193. .br
  7194.         50 - 59:  circles
  7195. .br
  7196. .br
  7197.         60 - 69:  squares
  7198. .br
  7199. .br
  7200.         70 - 79:  diamonds
  7201. .br
  7202. .br
  7203.         80 - 89:  upwards triangles
  7204. .br
  7205. .br
  7206.         90 - 99:  downwards triangles
  7207. .br
  7208. The size of these symbols is linked to the font size.  The depth of symbols
  7209. is by default one less than the depth for lines to achieve nice error bars.
  7210. If <pointtype> is above 1000, the depth is <layer> + <pointtype>/1000-1.  If
  7211. <pointtype>%1000 is above 100, the fill color is (<pointtype>%1000)/100-1.
  7212.  
  7213. Available fill colors are (from 1 to 9): black, blue, green, cyan, red,
  7214. magenta, yellow, white and dark blue (in monochrome mode: black for 1 to 6
  7215. and white for 7 to 9).
  7216.  
  7217. See \fBplot with\fR for details of <linetype> and <pointtype>.
  7218.  
  7219. The \fBbig\fR option is a substitute for the \fBbfig\fR terminal in earlier versions,
  7220. which is no longer supported.
  7221.  
  7222. Examples:
  7223. .br
  7224.       set terminal fig monochrome small pointsmax 1000  # defaults
  7225. .br
  7226.  
  7227. .br
  7228.       plot 'file.dat' with points linetype 102 pointtype 759
  7229. .br
  7230. would produce circles with a blue outline of width 1 and yellow fill color.
  7231.  
  7232. .br
  7233.       plot 'file.dat' using 1:2:3 with err linetype 1 pointtype 554
  7234. .br
  7235. would produce errorbars with black lines and circles filled red.  These
  7236. circles are one layer above the lines (at depth 9 by default).
  7237.  
  7238. To plot the error bars on top of the circles use
  7239. .br
  7240.       plot 'file.dat' using 1:2:3 with err linetype 1 pointtype 2554
  7241. .br
  7242. .sp 2
  7243. .NH 3
  7244. Gif
  7245. .sp 1
  7246. .LP
  7247. .XS
  7248. Gif
  7249. .XE
  7250. The \fBgif\fR terminal driver generates output in GIF format.  It uses Thomas
  7251. Boutell\&'s gd library, which is available from http://www.boutell.com/gd/
  7252.  
  7253. By default, the \fBgif\fR terminal driver uses a shared Web-friendy palette.
  7254. Syntax:
  7255. .br
  7256.       set terminal gif {transparent} {interlace}
  7257. .br
  7258. .br
  7259.                        {tiny | small | medium | large | giant}
  7260. .br
  7261. .br
  7262.                        {size <x>,<y>}
  7263. .br
  7264. .br
  7265.                        {<color0> <color1> <color2> ...}
  7266. .br
  7267.  
  7268. \fBtransparent\fR instructs the driver to generate transparent GIFs.  The first
  7269. color will be the transparent one.
  7270.  
  7271. \fBinterlace\fR instructs the driver to generate interlaced GIFs.
  7272.  
  7273. The choice of fonts is \fBtiny\fR (5x8 pixels), \fBsmall\fR (6x12 pixels), \fBmedium\fR
  7274. (7x13 Bold), \fBlarge\fR (8x16) or \fBgiant\fR (9x15 pixels)
  7275.  
  7276. The size <x,y> is given in pixels---it defaults to 640x480.  The number of
  7277. pixels can be also modified by scaling with the \fBset size\fR command.
  7278.  
  7279. Each color must be of the form \&'xrrggbb\&', where x is the literal character
  7280. \&\&'x\&' and \&'rrggbb\&' are the red, green and blue components in hex.  For example,
  7281. \&\&'x00ff00\&' is green.  The background color is set first, then the border
  7282. colors, then the X & Y axis colors, then the plotting colors.  The maximum
  7283. number of colors that can be set is 256.
  7284.  
  7285. Examples:
  7286. .br
  7287.       set terminal gif small size 640,480 \\
  7288. .br
  7289. .br
  7290.                        xffffff x000000 x404040 \\
  7291. .br
  7292. .br
  7293.                        xff0000 xffa500 x66cdaa xcdb5cd \\
  7294. .br
  7295. .br
  7296.                        xadd8e6 x0000ff xdda0dd x9500d3    # defaults
  7297. .br
  7298.  
  7299. which uses white for the non-transparent background, black for borders, gray
  7300. for the axes, and red, orange, medium aquamarine, thistle 3, light blue, blue,
  7301. plum and dark violet for eight plotting colors.
  7302.  
  7303. .br
  7304.       set terminal gif transparent xffffff \\
  7305. .br
  7306. .br
  7307.                        x000000 x202020 x404040 x606060 \\
  7308. .br
  7309. .br
  7310.                        x808080 xA0A0A0 xC0C0C0 xE0E0E0 \\
  7311. .br
  7312. which uses white for the transparent background, black for borders, dark
  7313. gray for axes, and a gray-scale for the six plotting colors.
  7314.  
  7315. The page size is 640x480 pixels.  The \fBgif\fR driver can create either color
  7316. or monochromatic output, but you have no control over which is produced.
  7317.  
  7318. The current version of the \fBgif\fR driver does not support animated GIFs.
  7319. .sp 2
  7320. .NH 3
  7321. Unixplot
  7322. .sp 1
  7323. .LP
  7324. .XS
  7325. Unixplot
  7326. .XE
  7327. The \fBunixplot\fR driver produces device-independent output in the GNU plot
  7328. graphics language.  The default size of the PostScript results generated by
  7329. "plot2ps" is 5 x 3 inches; this can be increased up to about 8.25 x 8.25 by
  7330. \fBset size\fR.
  7331.  
  7332. Syntax:
  7333. .br
  7334.       set terminal unixplot {"<fontname>"} {<fontsize>}
  7335. .br
  7336.  
  7337. which defaults to 10-point "Courier".
  7338.  
  7339. There is a non-GNU version of the \fBunixplot\fR driver which cannot be compiled
  7340. unless this version is left out.
  7341. .sp 2
  7342. .NH 3
  7343. Gpic
  7344. .sp 1
  7345. .LP
  7346. .XS
  7347. Gpic
  7348. .XE
  7349. The \fBgpic\fR terminal driver generates GPIC graphs in the Free Software
  7350. Foundations\&'s "groff" package.  The default size is 5 x 3 inches.  The only
  7351. option is the origin, which defaults to (0,0).
  7352.  
  7353. Syntax:
  7354. .br
  7355.       set terminal gpic {<x> <y>}
  7356. .br
  7357.  
  7358. where \fBx\fR and \fBy\fR are in inches.
  7359.  
  7360. A simple graph can be formatted using
  7361.  
  7362. .br
  7363.       groff -p -mpic -Tps file.pic > file.ps.
  7364. .br
  7365.  
  7366. The output from pic can be pipe-lined into eqn, so it is possible to put
  7367. complex functions in a graph with the \fBset label\fR and \fBset {x/y}label\fR
  7368. commands.  For instance,
  7369.  
  7370. .br
  7371.       set ylab '@space 0 int from 0 to x alpha ( t ) roman d t@'
  7372. .br
  7373.  
  7374. will label the y axis with a nice integral if formatted with the command:
  7375.  
  7376. .br
  7377.       gpic filename.pic | geqn -d@@ -Tps | groff -m[macro-package] -Tps
  7378. .br
  7379. .br
  7380.           > filename.ps
  7381. .br
  7382.  
  7383. Figures made this way can be scaled to fit into a document.  The pic language
  7384. is easy to understand, so the graphs can be edited by hand if need be.  All
  7385. co-ordinates in the pic-file produced by \fBgnuplot\fR are given as x+gnuplotx
  7386. and y+gnuploty.  By default x and y are given the value 0.  If this line is
  7387. removed with an editor in a number of files, one can put several graphs in
  7388. one figure like this (default size is 5.0x3.0 inches):
  7389.  
  7390. .br
  7391.       .PS 8.0
  7392. .br
  7393. .br
  7394.       x=0;y=3
  7395. .br
  7396. .br
  7397.       copy "figa.pic"
  7398. .br
  7399. .br
  7400.       x=5;y=3
  7401. .br
  7402. .br
  7403.       copy "figb.pic"
  7404. .br
  7405. .br
  7406.       x=0;y=0
  7407. .br
  7408. .br
  7409.       copy "figc.pic"
  7410. .br
  7411. .br
  7412.       x=5;y=0
  7413. .br
  7414. .br
  7415.       copy "figd.pic"
  7416. .br
  7417. .br
  7418.       .PE
  7419. .br
  7420.  
  7421. This will produce an 8-inch-wide figure with four graphs in two rows on top
  7422. of each other.
  7423.  
  7424. One can also achieve the same thing by the command
  7425.  
  7426. .br
  7427.       set terminal gpic x y
  7428. .br
  7429.  
  7430. for example, using
  7431.  
  7432. .br
  7433.       .PS 6.0
  7434. .br
  7435. .br
  7436.       copy "trig.pic"
  7437. .br
  7438. .br
  7439.       .PE
  7440. .br
  7441. .sp 2
  7442. .NH 3
  7443. Gpr
  7444. .sp 1
  7445. .LP
  7446. .XS
  7447. Gpr
  7448. .XE
  7449. The \fBgpr\fR terminal driver supports the Apollo Graphics Primitive Resource
  7450. for a fixed-size window.  It has no options.
  7451.  
  7452. If a variable window size is desired, use the \fBapollo\fR terminal instead.
  7453. .sp 2
  7454. .NH 3
  7455. Grass
  7456. .sp 1
  7457. .LP
  7458. .XS
  7459. Grass
  7460. .XE
  7461. The \fBgrass\fR terminal driver gives \fBgnuplot\fR capabilities to users of the 
  7462. GRASS geographic information system.  Contact grassp-list@moon.cecer.army.mil
  7463. for more information.  Pages are written to the current frame of the GRASS
  7464. Graphics Window.  There are no options.
  7465. .sp 2
  7466. .NH 3
  7467. Hp2623a
  7468. .sp 1
  7469. .LP
  7470. .XS
  7471. Hp2623a
  7472. .XE
  7473. The \fBhp2623a\fR terminal driver supports the Hewlett Packard HP2623A.  It has
  7474. no options.
  7475. .sp 2
  7476. .NH 3
  7477. Hp2648
  7478. .sp 1
  7479. .LP
  7480. .XS
  7481. Hp2648
  7482. .XE
  7483. The \fBhp2648\fR terminal driver supports the Hewlett Packard HP2647 and HP2648.
  7484. It has no options.
  7485. .sp 2
  7486. .NH 3
  7487. Hp500c
  7488. .sp 1
  7489. .LP
  7490. .XS
  7491. Hp500c
  7492. .XE
  7493. The \fBhp500c\fR terminal driver supports the Hewlett Packard HP DeskJet 500c.
  7494. It has options for resolution and compression.
  7495.  
  7496. Syntax:
  7497. .br
  7498.       set terminal hp500c {<res>} {<comp>}
  7499. .br
  7500.  
  7501. where \fBres\fR can be 75, 100, 150 or 300 dots per inch and \fBcomp\fR can be "rle",
  7502. or "tiff".  Any other inputs are replaced by the defaults, which are 75 dpi
  7503. and no compression.  Rasterization at the higher resolutions may require a
  7504. large amount of memory.
  7505. .sp 2
  7506. .NH 3
  7507. Hpgl
  7508. .sp 1
  7509. .LP
  7510. .XS
  7511. Hpgl
  7512. .XE
  7513. The \fBhpgl\fR driver produces HPGL output for devices like the HP7475A plotter.
  7514. There are two options which can be set---the number of pens and "eject", which
  7515. tells the plotter to eject a page when done.  The default is to use 6 pens
  7516. and not to eject the page when done.
  7517.  
  7518. The international character sets ISO-8859-1 and CP850 are recognized via
  7519. \fBset encoding iso_8859_1\fR or \fBset encoding cp850\fR (see \fBset encoding\fR for
  7520. details).
  7521.  
  7522. Syntax:
  7523. .br
  7524.       set terminal hpgl {<number_of_pens>} {eject}
  7525. .br
  7526.  
  7527. The selection
  7528.  
  7529. .br
  7530.       set terminal hpgl 8 eject
  7531. .br
  7532.  
  7533. is equivalent to the previous \fBhp7550\fR terminal, and the selection
  7534.  
  7535. .br
  7536.       set terminal hpgl 4
  7537. .br
  7538.  
  7539. is equivalent to the previous \fBhp7580b\fR terminal.
  7540.  
  7541. The \fBpcl5\fR driver supports the Hewlett-Packard Laserjet III.  It actually uses
  7542. HPGL-2, but there is a name conflict among the terminal devices.  It has
  7543. several options
  7544.  
  7545. Syntax:
  7546. .br
  7547.       set terminal pcl5 {<mode>} {<font>} {<fontsize>}
  7548. .br
  7549.  
  7550. where <mode> is \fBlandscape\fR, or \fBportrait\fR, <font> is \fBstick\fR, \fBunivers\fR, or
  7551. \fBcg_times\fR, and <fontsize> is the size in points.
  7552.  
  7553. With \fBpcl5\fR international characters are handled by the printer; you just put
  7554. the appropriate 8-bit character codes into the text strings.  You don\&'t need
  7555. to bother with \fBset encoding\fR.
  7556.  
  7557. HPGL graphics can be imported by many software packages.
  7558. .sp 2
  7559. .NH 3
  7560. Hpljii
  7561. .sp 1
  7562. .LP
  7563. .XS
  7564. Hpljii
  7565. .XE
  7566. The \fBhpljii\fR terminal driver supports the HP Laserjet Series II printer.  The
  7567. \fBhpdj\fR driver supports the HP DeskJet 500 printer.  These drivers allow a
  7568. choice of resolutions.
  7569.  
  7570. Syntax:
  7571. .br
  7572.       set terminal hpljii | hpdj {<res>}
  7573. .br
  7574.  
  7575. where \fBres\fR may be 75, 100, 150 or 300 dots per inch; the default is 75.
  7576. Rasterization at the higher resolutions may require a large amount of memory.
  7577.  
  7578. The \fBhp500c\fR terminal is similar to \fBhpdj\fR; \fBhp500c\fR additionally supports
  7579. color and compression.
  7580. .sp 2
  7581. .NH 3
  7582. Hppj
  7583. .sp 1
  7584. .LP
  7585. .XS
  7586. Hppj
  7587. .XE
  7588. The \fBhppj\fR terminal driver supports the HP PaintJet and HP3630 printers.  The
  7589. only option is the choice of font.
  7590.  
  7591. Syntax:
  7592. .br
  7593.       set terminal hppj {FNT5X9 | FNT9X17 | FNT13X25}
  7594. .br
  7595.  
  7596. with the middle-sized font (FNT9X17) being the default.
  7597. .sp 2
  7598. .NH 3
  7599. Imagen
  7600. .sp 1
  7601. .LP
  7602. .XS
  7603. Imagen
  7604. .XE
  7605. The \fBimagen\fR terminal driver supports Imagen laser printers.  It is capable
  7606. of placing multiple graphs on a single page.
  7607.  
  7608. Syntax:
  7609. .br
  7610.       set terminal imagen {<fontsize>} {portrait | landscape}
  7611. .br
  7612. .br
  7613.                           {[<horiz>,<vert>]}
  7614. .br
  7615.  
  7616. where \fBfontsize\fR defaults to 12 points and the layout defaults to \fBlandscape\fR.
  7617. \fB<horiz>\fR and \fB<vert>\fR are the number of graphs in the horizontal and
  7618. vertical directions; these default to unity.
  7619.  
  7620. Example:
  7621. .br
  7622.       set terminal imagen portrait [2,3]
  7623. .br
  7624.  
  7625. puts six graphs on the page in three rows of two in portrait orientation.
  7626. .sp 2
  7627. .NH 3
  7628. Iris4d
  7629. .sp 1
  7630. .LP
  7631. .XS
  7632. Iris4d
  7633. .XE
  7634. The \fBiris4d\fR terminal driver supports Silicon Graphics IRIS 4D computers.
  7635. Its only option is 8- or 24-bit color depth.  The default is 8.
  7636.  
  7637. Syntax:
  7638. .br
  7639.       set terminal iris4d {8 | 24}
  7640. .br
  7641.  
  7642. The color depth is not really a choice -- the value appropriate for the
  7643. hardware should be selected.
  7644.  
  7645. When using 24-bit mode, the colors can be directly specified via the file
  7646. \&.gnuplot_iris4d that is searched in the current directory and then in the
  7647. home directory specified by the HOME environment variable.  This file holds
  7648. RGB values for the background, border, labels and nine plotting colors, in
  7649. that order.  For example, here is a file containing the default colors:
  7650.  
  7651. .br
  7652.       85   85   85     Background   (dark gray)
  7653. .br
  7654. .br
  7655.       0    0    0      Boundary     (black)
  7656. .br
  7657. .br
  7658.       170  0    170    Labeling     (magenta)
  7659. .br
  7660. .br
  7661.       85   255  255    Plot Color 1 (light cyan)
  7662. .br
  7663. .br
  7664.       170  0    0      Plot Color 2 (red)
  7665. .br
  7666. .br
  7667.       0    170  0      Plot Color 3 (green)
  7668. .br
  7669. .br
  7670.       255  85   255    Plot Color 4 (light magenta)
  7671. .br
  7672. .br
  7673.       255  255  85     Plot Color 5 (yellow)
  7674. .br
  7675. .br
  7676.       255  85   85     Plot Color 6 (light red)
  7677. .br
  7678. .br
  7679.       85   255  85     Plot Color 7 (light green)
  7680. .br
  7681. .br
  7682.       0    170  170    Plot Color 8 (cyan)
  7683. .br
  7684. .br
  7685.       170  170  0      Plot Color 9 (brown)
  7686. .br
  7687.  
  7688. This file must have exactly 12 lines of RGB triples.  No empty lines are
  7689. allowed, and anything after the third number on a line is ignored.
  7690. .sp 2
  7691. .NH 3
  7692. Kyo
  7693. .sp 1
  7694. .LP
  7695. .XS
  7696. Kyo
  7697. .XE
  7698. The \fBkyo\fR and \fBprescribe\fR terminal drivers support the Kyocera laser printer.
  7699. The only difference between the two is that \fBkyo\fR uses "Helvetica" whereas
  7700. \fBprescribe\fR uses "Courier".  There are no options.
  7701. .sp 2
  7702. .NH 3
  7703. Latex
  7704. .sp 1
  7705. .LP
  7706. .XS
  7707. Latex
  7708. .XE
  7709. The \fBlatex\fR and \fBemtex\fR drivers allow two options.
  7710.  
  7711. Syntax:
  7712. .br
  7713.       set terminal latex | emtex {courier | roman | default} {<fontsize>}
  7714. .br
  7715.  
  7716. \fBfontsize\fR may be any size you specify.  The default is for the plot to
  7717. inherit its font setting from the embedding document.
  7718.  
  7719. Unless your driver is capable of building fonts at any size (e.g. dvips),
  7720. stick to the standard 10, 11 and 12 point sizes.
  7721.  
  7722. METAFONT users beware: METAFONT does not like odd sizes.
  7723.  
  7724. All drivers for LaTeX offer a special way of controlling text positioning:
  7725. If any text string begins with \&'{\&', you also need to include a \&'}\&' at the
  7726. end of the text, and the whole text will be centered both horizontally and
  7727. vertically.  If the text string begins with \&'[\&', you need to follow this with
  7728. a position specification (up to two out of t,b,l,r), \&']{\&', the text itself,
  7729. and finally \&'}\&'.  The text itself may be anything LaTeX can typeset as an
  7730. LR-box.  \&'\\rule{}{}\&'s may help for best positioning.
  7731.  
  7732. Points, among other things, are drawn using the LaTeX commands "\\Diamond" and
  7733. "\\Box".  These commands no longer belong to the LaTeX2e core; they are included
  7734. in the latexsym package, which is part of the base distribution and thus part
  7735. of any LaTeX implementation.  Please do not forget to use this package.
  7736.  
  7737. Points are drawn with the LaTex commands \\Diamond and \\Box.  These
  7738. commands do no longer belong to the LaTeX2e core, but are included in the
  7739. latexsym-package in the base distribution, and are hence part of all LaTeX
  7740. implementations. Please do not forget to use this package.
  7741.  
  7742. Examples:
  7743. About label positioning:
  7744. Use gnuplot defaults (mostly sensible, but sometimes not really best):
  7745. .br
  7746.        set title '\\LaTeX\\ -- $ \\gamma $'
  7747. .br
  7748. Force centering both horizontally and vertically:
  7749. .br
  7750.        set label '{\\LaTeX\\ -- $ \\gamma $}' at 0,0
  7751. .br
  7752. Specify own positioning (top here):
  7753. .br
  7754.        set xlabel '[t]{\\LaTeX\\ -- $ \\gamma $}'
  7755. .br
  7756. The other label -- account for long ticlabels:
  7757. .br
  7758.        set ylabel '[r]{\\LaTeX\\ -- $ \\gamma $\\rule{7mm}{0pt}'
  7759. .br
  7760. .sp 2
  7761. .NH 3
  7762. Linux
  7763. .sp 1
  7764. .LP
  7765. .XS
  7766. Linux
  7767. .XE
  7768. The \fBlinux\fR driver has no additional options to specify.  It looks at the
  7769. environment variable GSVGAMODE for the default mode; if not set, it uses
  7770. 1024x768x256 as default mode or, if that is not possible, 640x480x16
  7771. (standard VGA).
  7772. .sp 2
  7773. .NH 3
  7774. Macintosh
  7775. .sp 1
  7776. .LP
  7777. .XS
  7778. Macintosh
  7779. .XE
  7780. Several options may be set in the \&'macintosh\&' driver.
  7781.  
  7782. Syntax:
  7783. .br
  7784.      set terminal macintosh {singlewin | multiwin} {vertical | novertical}
  7785. .br
  7786. .br
  7787.                             {size <width>, <height> | default}
  7788. .br
  7789.  
  7790. \&\&'singlewin\&' limits the output to a single window and is useful for animations.
  7791. \&\&'multiwin\&' allows multiple windows.
  7792. \&\&'vertical\&' is only valid under the gx option. With this option, rotated text
  7793. .br
  7794.     be drawn vertically. novertical turns this option off.
  7795. .br
  7796. .br
  7797.  size <width>, <height> overrides the graph size set in the preferences
  7798. .br
  7799. .br
  7800.     dialog until it is cleared with either 'set term mac size default'
  7801. .br
  7802. .br
  7803.     or 'set term mac default'.
  7804. .br
  7805.  
  7806. .br
  7807.  'set term mac size default' sets the window size settings to those set in
  7808. .br
  7809. .br
  7810.     the preferences dialog.
  7811. .br
  7812.  
  7813. .br
  7814.  'set term mac default' sets all options to their default values.
  7815. .br
  7816. .br
  7817.     Default values: nogx, multiwin, novertical.
  7818. .br
  7819.  
  7820. .br
  7821.  If you generate graphs under the multiwin option and then switch to singlewin,
  7822. .br
  7823. .br
  7824.  the next plot command will cause one more window to be created. This new
  7825. .br
  7826. .br
  7827.  window will be reused as long as singlewin is in effect. If you switch back
  7828. .br
  7829. .br
  7830.  to multiwin, generate some graphs, and then switch to singlewin again, the
  7831. .br
  7832. .br
  7833.  orginal 'singlewin' window will be resused if it is still open. Otherwise
  7834. .br
  7835. .br
  7836.  a new 'singlewin' window will be created. The 'singlewin' window is not numbered.
  7837. .br
  7838. .sp 2
  7839. .NH 3
  7840. Mf
  7841. .sp 1
  7842. .LP
  7843. .XS
  7844. Mf
  7845. .XE
  7846. The \fBmf\fR terminal driver creates a input file to the METAFONT program.  Thus a
  7847. figure may be used in the TeX document in the same way as is a character.
  7848.  
  7849. To use a picture in a document, the METAFONT program must be run with the
  7850. output file from \fBgnuplot\fR as input.  Thus, the user needs a basic knowledge
  7851. of the font creating process and the procedure for including a new font in a
  7852. document.  However, if the METAFONT program is set up properly at the local
  7853. site, an unexperienced user could perform the operation without much trouble.
  7854.  
  7855. The text support is based on a METAFONT character set.  Currently the
  7856. Computer Modern Roman font set is input, but the user is in principal free to
  7857. chose whatever fonts he or she needs.  The METAFONT source files for the
  7858. chosen font must be available.  Each character is stored in a separate
  7859. picture variable in METAFONT.  These variables may be manipulated (rotated,
  7860. scaled etc.) when characters are needed.  The drawback is the interpretation
  7861. time in the METAFONT program.  On some machines (i.e. PC) the limited amount
  7862. of memory available may also cause problems if too many pictures are stored.
  7863.  
  7864. The \fBmf\fR terminal has no options.
  7865. .sp 2
  7866. .RS
  7867. .IP
  7868. .NH 4
  7869. METAFONT Instructions
  7870. .sp 1
  7871. .LP
  7872. .XS
  7873. METAFONT Instructions
  7874. .XE
  7875.  
  7876. - Set your terminal to METAFONT:
  7877. .br
  7878.   set terminal mf
  7879. .br
  7880. - Select an output-file, e.g.:
  7881. .br
  7882.   set output "myfigures.mf"
  7883. .br
  7884. - Create your pictures. Each picture will generate a separate character. Its
  7885. default size will be 5*3 inches. You can change the size by saying \fBset size
  7886. 0.5,0.5\fR or whatever fraction of the default size you want to have.
  7887.  
  7888. - Quit \fBgnuplot\fR.
  7889.  
  7890. - Generate a TFM and GF file by running METAFONT on the output of \fBgnuplot\fR.
  7891. Since the picture is quite large (5*3 in), you will have to use a version of
  7892. METAFONT that has a value of at least 150000 for memmax.  On Unix systems
  7893. these are conventionally installed under the name bigmf.  For the following
  7894. assume that the command virmf stands for a big version of METAFONT.  For
  7895. example:
  7896.  
  7897. - Invoke METAFONT:
  7898. .br
  7899.     virmf '&plain'
  7900. .br
  7901. - Select the output device: At the METAFONT prompt (\&'*\&') type:
  7902. .br
  7903.     \\mode:=CanonCX;     % or whatever printer you use
  7904. .br
  7905. - Optionally select a magnification:
  7906. .br
  7907.     mag:=1;             % or whatever you wish
  7908. .br
  7909. - Input the \fBgnuplot\fR-file:
  7910. .br
  7911.     input myfigures.mf
  7912. .br
  7913. On a typical Unix machine there will usually be a script called "mf" that
  7914. executes virmf \&'&plain\&', so you probably can substitute mf for virmf &plain.
  7915. This will generate two files: mfput.tfm and mfput.$$$gf (where $$$ indicates
  7916. the resolution of your device).  The above can be conveniently achieved by
  7917. typing everything on the command line, e.g.:
  7918. virmf \&'&plain\&' \&'\\mode:=CanonCX; mag:=1; input myfigures.mf\&'
  7919. In this case the output files will be named myfigures.tfm and
  7920. myfigures.300gf.
  7921.  
  7922. - Generate a PK file from the GF file using gftopk:
  7923. .br
  7924.   gftopk myfigures.300gf myfigures.300pk
  7925. .br
  7926. The name of the output file for gftopk depends on the DVI driver you use.
  7927. Ask your local TeX administrator about the naming conventions.  Next, either
  7928. install the TFM and PK files in the appropriate directories, or set your
  7929. environment variables properly.  Usually this involves setting TEXFONTS to
  7930. include the current directory and doing the same thing for the environment
  7931. variable that your DVI driver uses (no standard name here...).  This step is
  7932. necessary so that TeX will find the font metric file and your DVI driver will
  7933. find the PK file.
  7934.  
  7935. - To include your pictures in your document you have to tell TeX the font:
  7936. .br
  7937.   \\font\\gnufigs=myfigures
  7938. .br
  7939. Each picture you made is stored in a single character.  The first picture is
  7940. character 0, the second is character 1, and so on...  After doing the above
  7941. step, you can use the pictures just like any other characters.  Therefore, to
  7942. place pictures 1 and 2 centered in your document, all you have to do is:
  7943. .br
  7944.   \\centerline{\\gnufigs\\char0}
  7945. .br
  7946. .br
  7947.   \\centerline{\\gnufigs\\char1}
  7948. .br
  7949. in plain TeX.  For LaTeX you can, of course, use the picture environment and
  7950. place the picture wherever you wish by using the \\makebox and \\put macros.
  7951.  
  7952. This conversion saves you a lot of time once you have generated the font;
  7953. TeX handles the pictures as characters and uses minimal time to place them,
  7954. and the documents you make change more often than the pictures do.  It also
  7955. saves a lot of TeX memory.  One last advantage of using the METAFONT driver
  7956. is that the DVI file really remains device independent, because no \\special
  7957. commands are used as in the eepic and tpic drivers.
  7958. .sp 2
  7959. .RE
  7960. .br
  7961. .NH 3
  7962. Mp
  7963. .sp 1
  7964. .LP
  7965. .XS
  7966. Mp
  7967. .XE
  7968.  
  7969. The \fBmp\fR driver produces output intended to be input to the Metapost program.
  7970. Running Metapost on the file creates EPS files containing the plots. By
  7971. default, Metapost passes all text through TeX.  This has the advantage of
  7972. allowing essentially  any TeX symbols in titles and labels.
  7973.  
  7974. The \fBmp\fR terminal is selected with a command of the form
  7975. .br
  7976.    set term mp {color} {solid} {notex} {mag <magsize>} {"<name>"} {<size>}
  7977. .br
  7978. The option \fBcolor\fR causes lines to be drawn in color (on a printer or display
  7979. that supports it), \fBmonochrome\fR (or nothing) selects black lines.  The option
  7980. \fBsolid\fR draws solid lines, while \fBdashed\fR (or nothing) selects lines with
  7981. different patterns of dashes.  If \fBsolid\fR is selected but \fBcolor\fR is not,
  7982. nearly all lines will be identical.  This may occasionally be useful, so it is
  7983. allowed.
  7984.  
  7985. The option \fBnotex\fR bypasses TeX entirely, therefore no TeX code can be used in
  7986. labels under this option.  This is intended for use on old plot files or files
  7987. that make frequent use of common characters like \fB$\fR and \fB%\fR that require
  7988. special handling in TeX.
  7989.  
  7990. Changing font sizes in TeX has no effect on the size of mathematics, and there
  7991. is no foolproof way to make such a change, except by globally  setting a
  7992. magnification factor. This is the purpose of the \fBmagnification\fR option. It
  7993. must be followed by a scaling factor. All text (NOT the graphs) will be scaled
  7994. by this factor. Use this if you have math that you want at some size other
  7995. than the default 10pt. Unfortunately, all math will be the same size, but see
  7996. the discussion below on editing the MP output. \fBmag\fR will also work under
  7997. \fBnotex\fR but there seems no point in using it as the font size option (below)
  7998. works as well.
  7999.  
  8000. A name in quotes selects the font that will be used when no explicit font is
  8001. given in a \fBset label\fR or \fBset title\fR.  A name recognized by TeX (a TFM file
  8002. exists) must be used.  The default is "cmr10" unless \fBnotex\fR is selected,
  8003. then it is "pcrr8r" (Courier).  Even under \fBnotex\fR, a TFM file is needed by
  8004. Metapost. The file \fBpcrr8r.tfm\fR is the name given to Courier in LaTeX\&'s psnfss
  8005. package.  If you change the font from the \fBnotex\fR default, choose a font that
  8006. matches the ASCII encoding at least in the range 32-126.  \fBcmtt10\fR almost
  8007. works, but it has a nonblank character in position 32 (space).
  8008.  
  8009. The size can be any number between 5.0 and 99.99.  If it is omitted, 10.0 is
  8010. used.  It is advisable to use \fBmagstep\fR sizes: 10 times an integer or
  8011. half-integer power of 1.2, rounded to two decimals, because those are the most
  8012. available sizes of fonts in TeX systems.
  8013.  
  8014. All the options are optional.  If font information is given, it must be at the
  8015. end, with size (if present) last.  The size is needed to select a size for the
  8016. font, even if the font name includes size information.  For example,
  8017. \fBset term mp "cmtt12"\fR selects cmtt12 shrunk to the default size 10.  This
  8018. is probably not what you want or you would have used cmtt10.
  8019.  
  8020. The following common ascii characters need special treatment in TeX:
  8021. .br
  8022.    $, &, #, %, _;  |, <, >;  ^, ~,  \\, {, and }
  8023. .br
  8024. The five characters $, #, &, _, and % can simply be escaped, e.g., \fB\\$\fR.
  8025. The three characters <, >, and | can be wrapped in math mode, e.g., \fB$<$\fR.
  8026. The remainder require some TeX work-arounds.  Any good book on TeX will give
  8027. some guidance.
  8028.  
  8029. If you type your labels inside double quotes, backslashes in TeX code need to
  8030. be escaped (doubled). Using single quotes will avoid having to do this, but
  8031. then you cannot use \fB\\n\fR for line breaks.  As of this writing, version 3.7 of
  8032. gnuplot processess titles given in a \fBplot\fR command differently than in other
  8033. places, and backslashes in TeX commands need to be doubled regardless of the
  8034. style of quotes.
  8035.  
  8036. Metapost pictures are typically used in TeX documents.  Metapost deals with
  8037. fonts pretty much the same way TeX does, which is different from most other
  8038. document preparation programs.  If the picture is included in a LaTeX document
  8039. using the graphics package, or in a plainTeX document via epsf.tex, and then
  8040. converted to PostScript with dvips (or other dvi-to-ps converter), the text in
  8041. the plot will usually be handled correctly.  However, the text may not appear
  8042. if you send the Metapost output as-is to a PostScript interpreter.
  8043.  
  8044. .sp 2
  8045. .RS
  8046. .IP
  8047. .NH 4
  8048. Metapost Instructions
  8049. .sp 1
  8050. .LP
  8051. .XS
  8052. Metapost Instructions
  8053. .XE
  8054.  
  8055. - Set your terminal to Metapost, e.g.:
  8056. .br
  8057.    set terminal mp mono "cmtt12" 12
  8058. .br
  8059.  
  8060. - Select an output-file, e.g.:
  8061. .br
  8062.    set output "figure.mp"
  8063. .br
  8064.  
  8065. - Create your pictures.  Each plot (or multiplot group) will generate a
  8066. separate Metapost beginfig...endfig group.  Its default size will be 5 by 3
  8067. inches.  You can change the size by saying \fBset size 0.5,0.5\fR or whatever
  8068. fraction of the default size you want to have.
  8069.  
  8070. - Quit gnuplot.
  8071.  
  8072. - Generate EPS files by running Metapost on the output of gnuplot:
  8073. .br
  8074.    mpost figure.mp  OR  mp figure.mp
  8075. .br
  8076. The name of the Metapost program depends on the system, typically \fBmpost\fR for
  8077. a Unix machine and \fBmp\fR on many others.  Metapost will generate one EPS file
  8078. for each picture.
  8079.  
  8080. - To include your pictures in your document you can use the graphics package
  8081. in LaTeX or epsf.tex in plainTeX:
  8082. .br
  8083.    \\usepackage{graphics} % LaTeX
  8084. .br
  8085. .br
  8086.    \\input epsf.tex       % plainTeX
  8087. .br
  8088. If you use a driver other than dvips for converting TeX DVI output to PS, you
  8089. may need to add the following line in your LaTeX document:
  8090. .br
  8091.    \\DeclareGraphicsRule{*}{eps}{*}{}
  8092. .br
  8093. Each picture you made is in a separate file.  The first picture is in, e.g.,
  8094. figure.0, the second in figure.1, and so on....  To place the third picture in
  8095. your document, for example, all you have to do is:
  8096. .br
  8097.    \\includegraphics{figure.2} % LaTeX
  8098. .br
  8099. .br
  8100.    \\epsfbox{figure.2}         % plainTeX
  8101. .br
  8102.  
  8103. The advantage, if any, of the mp terminal over a postscript terminal is
  8104. editable output.  Considerable effort went into making this output as clean as
  8105. possible.  For those knowledgeable in the Metapost language, the default line
  8106. types and colors can be changed by editing the arrays \fBlt[]\fR and \fBcol[]\fR.
  8107. The choice of solid vs dashed lines, and color vs black lines can be change by
  8108. changing the values assigned to the booleans \fBdashedlines\fR and \fBcolorlines\fR.
  8109. If the default \fBtex\fR option was in effect, global changes to the text of
  8110. labels can be achieved by editing the \fBvebatimtex...etex\fR block.  In
  8111. particular, a LaTeX preamble can be added if desired, and then LaTeX\&'s
  8112. built-in size changing commands can be used for maximum flexibility. Be sure
  8113. to set the appropriate MP configuration variable to force Metapost to run
  8114. LaTeX instead of plainTeX.
  8115. .sp 2
  8116. .RE
  8117. .br
  8118. .NH 3
  8119. Mgr
  8120. .sp 1
  8121. .LP
  8122. .XS
  8123. Mgr
  8124. .XE
  8125. The \fBmgr\fR terminal driver supports the Mgr Window system.  It has no options.
  8126. .sp 2
  8127. .NH 3
  8128. Mif
  8129. .sp 1
  8130. .LP
  8131. .XS
  8132. Mif
  8133. .XE
  8134. The \fBmif\fR terminal driver produces Frame Maker MIF format version 3.00.  It
  8135. plots in MIF Frames with the size 15*10 cm, and plot primitives with the same
  8136. pen will be grouped in the same MIF group.  Plot primitives in a \fBgnuplot\fR
  8137. page will be plotted in a MIF Frame, and several MIF Frames are collected in
  8138. one large MIF Frame.  The MIF font used for text is "Times".
  8139.  
  8140. Several options may be set in the MIF 3.00 driver.
  8141.  
  8142. Syntax:
  8143. .br
  8144.       set terminal mif {colour | monochrome} {polyline | vectors}
  8145. .br
  8146. .br
  8147.                        {help | ?}
  8148. .br
  8149.  
  8150. \fBcolour\fR plots lines with line types >= 0 in colour (MIF sep. 2--7) and
  8151. \fBmonochrome\fR plots all line types in black (MIF sep. 0).
  8152. \fBpolyline\fR plots curves as continuous curves and \fBvectors\fR plots curves as
  8153. collections of vectors.
  8154. \fBhelp\fR and \fB?\fR print online help on standard error output---both print a
  8155. short description of the usage; \fBhelp\fR also lists the options;
  8156.  
  8157. Examples:
  8158. .br
  8159.       set term mif colour polylines    # defaults
  8160. .br
  8161. .br
  8162.       set term mif                     # defaults
  8163. .br
  8164. .br
  8165.       set term mif vectors
  8166. .br
  8167. .br
  8168.       set term mif help
  8169. .br
  8170. .sp 2
  8171. .NH 3
  8172. Mtos
  8173. .sp 1
  8174. .LP
  8175. .XS
  8176. Mtos
  8177. .XE
  8178. The \fBmtos\fR terminal has no options.  It sends data via a pipe to an external
  8179. program called GPCLIENT.  It runs under MULTITOS, Magic 3.x, MagicMAC. and
  8180. MiNT.  If you cannot find GPCLIENT, than mail to dirk@lstm.uni-erlangen.de.
  8181. .sp 2
  8182. .NH 3
  8183. Next
  8184. .sp 1
  8185. .LP
  8186. .XS
  8187. Next
  8188. .XE
  8189. Several options may be set in the next driver.
  8190.  
  8191. Syntax:
  8192. .br
  8193.       set terminal next {<mode>} {<type> } {<color>} {<dashed>}
  8194. .br
  8195. .br
  8196.                  {"<fontname>"} {<fontsize>} title {"<newtitle>"}
  8197. .br
  8198.  
  8199. where <mode> is  \fBdefault\fR, which sets all options to their defaults;
  8200. <type> is either \fBnew\fR or \fBold\fR, where \fBold\fR invokes the old single window;
  8201. <color> is either \fBcolor\fR or \fBmonochrome\fR;
  8202. <dashed> is either \fBsolid\fR or \fBdashed\fR;
  8203. "<fontname>" is the name of a valid PostScript font;
  8204. <fontsize> is the size of the font in PostScript points; and
  8205. <title> is the title for the GnuTerm window.
  8206. Defaults are  \fBnew\fR, \fBmonochrome\fR, \fBdashed\fR, "Helvetica", 14pt.
  8207.  
  8208. Examples:
  8209. .br
  8210.       set term next default
  8211. .br
  8212. .br
  8213.       set term next 22
  8214. .br
  8215. .br
  8216.       set term next color "Times-Roman" 14
  8217. .br
  8218. .br
  8219.       set term next color "Helvetica" 12 title "MyPlot"
  8220. .br
  8221. .br
  8222.       set term next old
  8223. .br
  8224.  
  8225. Pointsizes may be changed with \fBset linestyle\fR.
  8226. .sp 2
  8227. .NH 3
  8228. Next
  8229. .sp 1
  8230. .LP
  8231. .XS
  8232. Next
  8233. .XE
  8234. Several options may be set in the next driver.
  8235.  
  8236. Syntax:
  8237. .br
  8238.       set terminal next {<mode>} {<type> } {<color>} {<dashed>}
  8239. .br
  8240. .br
  8241.                  {"<fontname>"} {<fontsize>} title {"<newtitle>"}
  8242. .br
  8243.  
  8244. where <mode> is  \fBdefault\fR, which sets all options to their defaults;
  8245. <type> is either \fBnew\fR or \fBold\fR, where \fBold\fR invokes the old single window;
  8246. <color> is either \fBcolor\fR or \fBmonochrome\fR;
  8247. <dashed> is either \fBsolid\fR or \fBdashed\fR;
  8248. "<fontname>" is the name of a valid PostScript font;
  8249. <fontsize> is the size of the font in PostScript points; and
  8250. <title> is the title for the GnuTerm window.
  8251. Defaults are  \fBnew\fR, \fBmonochrome\fR, \fBdashed\fR, "Helvetica", 14pt.
  8252.  
  8253. Examples:
  8254. .br
  8255.       set term next default
  8256. .br
  8257. .br
  8258.       set term next 22
  8259. .br
  8260. .br
  8261.       set term next color "Times-Roman" 14
  8262. .br
  8263. .br
  8264.       set term next color "Helvetica" 12 title "MyPlot"
  8265. .br
  8266. .br
  8267.       set term next old
  8268. .br
  8269.  
  8270. Pointsizes may be changed with \fBset linestyle\fR.
  8271. .sp 2
  8272. .NH 3
  8273. Pbm
  8274. .sp 1
  8275. .LP
  8276. .XS
  8277. Pbm
  8278. .XE
  8279. Several options may be set in the \fBpbm\fR terminal---the driver for PBMplus.
  8280.  
  8281. Syntax:
  8282. .br
  8283.       set terminal pbm {<fontsize>} {<mode>}
  8284. .br
  8285.  
  8286. where <fontsize> is \fBsmall\fR, \fBmedium\fR, or \fBlarge\fR and <mode> is \fBmonochrome\fR,
  8287. \fBgray\fR or \fBcolor\fR.  The default plot size is 640 pixels wide and 480 pixels
  8288. high; this may be changed by \fBset size\fR.
  8289.  
  8290. The output of the \fBpbm\fR driver depends upon <mode>: \fBmonochrome\fR produces a
  8291. portable bitmap (one bit per pixel), \fBgray\fR a portable graymap (three bits
  8292. per pixel) and \fBcolor\fR a portable pixmap (color, four bits per pixel).
  8293.  
  8294. The output of this driver can be used with Jef Poskanzer\&'s excellent PBMPLUS
  8295. package, which provides programs to convert the above PBMPLUS formats to GIF,
  8296. TIFF, MacPaint, Macintosh PICT, PCX, X11 bitmap and many others.  PBMPLUS may
  8297. be obtained from ftp.x.org.  The relevant files have names that begin with
  8298. "netpbm-1mar1994.p1"; they reside in /contrib/utilities.  The package can
  8299. probably also be obtained from one of the many sites that mirrors ftp.x.org.
  8300.  
  8301. Examples:
  8302. .br
  8303.       set terminal pbm small monochrome             # defaults
  8304. .br
  8305. .br
  8306.       set size 2,2; set terminal pbm color medium
  8307. .br
  8308. .sp 2
  8309. .NH 3
  8310. Dospc
  8311. .sp 1
  8312. .LP
  8313. .XS
  8314. Dospc
  8315. .XE
  8316. The \fBdospc\fR terminal driver supports PCs with arbitrary graphics boards, which
  8317. will be automatically detected.  It should be used only if you are not using
  8318. the gcc or Zortec C/C++ compilers.
  8319. .sp 2
  8320. .NH 3
  8321. Pm
  8322. .sp 1
  8323. .LP
  8324. .XS
  8325. Pm
  8326. .XE
  8327. The \fBpm\fR terminal driver provides an OS/2 Presentation Manager window in
  8328. which the graph is plotted.  The window is opened when the first graph is
  8329. plotted.  This window has its own online help as well as facilities for
  8330. printing, copying to the clipboard and some line type and color adjustments.
  8331. The \fBmultiplot\fR option is supported.
  8332.  
  8333. Syntax:
  8334. .br
  8335.       set terminal pm {server {n}} {persist} {widelines} {enhanced} {"title"}
  8336. .br
  8337.  
  8338. If \fBpersist\fR is specified, each graph appears in its own window and all
  8339. windows remain open after \fBgnuplot\fR exits.  If \fBserver\fR is specified, all
  8340. graphs appear in the same window, which remains open when \fBgnuplot\fR exits.
  8341. This option takes an optional numerical argument which specifies an instance
  8342. of the server process.  Thus multiple server windows can be in use at the
  8343. same time.
  8344.  
  8345. If \fBwidelines\fR is specified, all plots will be drawn with wide lines.  If
  8346. \fBenhanced\fR is specified, sub- and superscripts and multiple fonts are
  8347. enabled using the same syntax as the \fBenhanced postscript\fR option (see
  8348. \fBset terminal postscript enhanced\fR for details).  Font names for the basic
  8349. PostScript fonts may be abbreviated to single letters.
  8350.  
  8351. If \fBtitle\fR is specified, it will be used as the title of the plot window.
  8352. It will also be used as the name of the server instance, and will override
  8353. the optional numerical argument.
  8354.  
  8355. Linewidths may be changed with \fBset linestyle\fR.
  8356. .sp 2
  8357. .NH 3
  8358. Png
  8359. .sp 1
  8360. .LP
  8361. .XS
  8362. Png
  8363. .XE
  8364. The \fBpng\fR terminal driver supports Portable Network Graphics.  To compile it,
  8365. you will need  the third-party libraries "libpng" and "zlib"; both are
  8366. available at ftp://ftp.uu.net/graphics/png.  \fBpng\fR has two options.
  8367.  
  8368. Syntax:
  8369. .br
  8370.       set terminal png {small | medium | large}
  8371. .br
  8372. .br
  8373.                        {monochrome | gray | color}
  8374. .br
  8375.  
  8376. The defaults are small (fontsize) and monochrome.  Default size of the output
  8377. is 640*480 pixel.
  8378. .sp 2
  8379. .NH 3
  8380. Postscript
  8381. .sp 1
  8382. .LP
  8383. .XS
  8384. Postscript
  8385. .XE
  8386. Several options may be set in the \fBpostscript\fR driver.
  8387.  
  8388. Syntax:
  8389. .br
  8390.       set terminal postscript {<mode>} {enhanced | noenhanced}
  8391. .br
  8392. .br
  8393.                               {color | monochrome} {solid | dashed}
  8394. .br
  8395. .br
  8396.                               {<duplexing>}
  8397. .br
  8398. .br
  8399.                               {"<fontname>"} {<fontsize>}
  8400. .br
  8401.  
  8402. where <mode> is \fBlandscape\fR, \fBportrait\fR, \fBeps\fR or \fBdefault\fR;
  8403. \fBsolid\fR draws all plots with solid lines, overriding any dashed patterns;
  8404. <duplexing> is \fBdefaultplex\fR, \fBsimplex\fR or \fBduplex\fR ("duplexing" in
  8405. PostScript is the ability of the printer to print on both sides of the same
  8406. page---don\&'t set this if your printer can\&'t do it);
  8407. \fBenhanced\fR activates the "enhanced PostScript" features (subscripts,
  8408. superscripts and mixed fonts);
  8409. \fB"<fontname>"\fR is the name of a valid PostScript font; and \fB<fontsize>\fR is
  8410. the size of the font in PostScript points.
  8411.  
  8412. \fBdefault\fR mode sets all options to their defaults: \fBlandscape\fR, \fBmonochrome\fR,
  8413. \fBdashed\fR, \fBdefaultplex\fR, \fBnoenhanced\fR, "Helvetica" and 14pt.
  8414. .br
  8415.  Default size of a PostScript plot is 10 inches wide and 7 inches high.
  8416. .br
  8417.  
  8418. \fBeps\fR mode generates EPS (Encapsulated PostScript) output, which is just
  8419. regular PostScript with some additional lines that allow the file to be
  8420. imported into a variety of other applications.  (The added lines are
  8421. PostScript comment lines, so the file may still be printed by itself.)  To
  8422. get EPS output, use the \fBeps\fR mode and make only one plot per file.  In \fBeps\fR
  8423. mode the whole plot, including the fonts, is reduced to half of the default
  8424. size.
  8425.  
  8426. Examples:
  8427. .br
  8428.       set terminal postscript default       # old postscript
  8429. .br
  8430. .br
  8431.       set terminal postscript enhanced      # old enhpost
  8432. .br
  8433. .br
  8434.       set terminal postscript landscape 22  # old psbig
  8435. .br
  8436. .br
  8437.       set terminal postscript eps 14        # old epsf1
  8438. .br
  8439. .br
  8440.       set terminal postscript eps 22        # old epsf2
  8441. .br
  8442. .br
  8443.       set size 0.7,1.4; set term post portrait color "Times-Roman" 14
  8444. .br
  8445.  
  8446. Linewidths and pointsizes may be changed with \fBset linestyle\fR.
  8447.  
  8448. The \fBpostscript\fR driver supports about 70 distinct pointtypes, selectable
  8449. through the \fBpointtype\fR option on \fBplot\fR and \fBset linestyle\fR.
  8450.  
  8451. Several possibly useful files about \fBgnuplot\fR\&'s PostScript are included
  8452. in the /docs/ps subdirectory of the \fBgnuplot\fR distribution and at the
  8453. distribution sites.  These are "ps_symbols.gpi" (a \fBgnuplot\fR command file
  8454. that, when executed, creates the file "ps_symbols.ps" which shows all the
  8455. symbols available through the \fBpostscript\fR terminal), "ps_guide.ps" (a
  8456. PostScript file that contains a summary of the enhanced syntax and a page
  8457. showing what the octal codes produce with text and symbol fonts) and
  8458. "ps_file.doc" (a text file that contains a discussion of the organization
  8459. of a PostScript file written by \fBgnuplot\fR).
  8460.  
  8461. A PostScript file is editable, so once \fBgnuplot\fR has created one, you are
  8462. free to modify it to your heart\&'s desire.  See the "editing postscript"
  8463. section for some hints.
  8464. .sp 2
  8465. .RS
  8466. .IP
  8467. .NH 4
  8468. Enhanced postscript
  8469. .sp 1
  8470. .LP
  8471. .XS
  8472. Enhanced postscript
  8473. .XE
  8474.  
  8475. .EQ
  8476. delim $$
  8477. .EN
  8478. .KS
  8479. .TS
  8480. center box tab (@) ;
  8481. c c l .
  8482. .TE
  8483. .TS
  8484. center box tab ($) ;
  8485. c c l .
  8486. Control$Examples$Explanation
  8487. _
  8488. ^$a^x$superscript
  8489. \&_$a\&_x$subscript
  8490.  @ $ @x or a\&@^b\&_c$phantom box (occupies no width)
  8491.  & $ &{space}$inserts space of specified length
  8492. .TE
  8493. .KE
  8494. .EQ
  8495. delim off
  8496. .EN
  8497.  
  8498.  
  8499. Braces can be used to place multiple-character text where a single character
  8500. is expected (e.g., 2^{10}).  To change the font and/or size, use the full
  8501. form:  {/[fontname][=fontsize | *fontscale] text}.  Thus {/Symbol=20 G} is a
  8502. 20-point GAMMA) and {/*0.75 K} is a K at three-quarters of whatever fontsize
  8503. is currently in effect.  (The \&'/\&' character MUST be the first character after
  8504. the \&'{\&'.)
  8505.  
  8506. If the encoding vector has been changed by \fBset encoding\fR, the default
  8507. encoding vector can be used instead by following the slash with a dash.  This
  8508. is unnecessary if you use the Symbol font, however---since /Symbol uses its
  8509. own encoding vector, \fBgnuplot\fR will not apply any other encoding vector to
  8510. it.
  8511.  
  8512. The phantom box is useful for a@^b_c to align superscripts and subscripts
  8513. but does not work well for overwriting an accent on a letter.  (To do the
  8514. latter, it is much better to use \fBset encoding iso_8859_1\fR to change to the
  8515. ISO Latin-1 encoding vector, which contains a large variety of letters with
  8516. accents or other diacritical marks.)  Since the box is non-spacing, it is
  8517. sensible to put the shorter of the subscript or superscript in the box (that
  8518. is, after the @).
  8519.  
  8520. Space equal in length to a string can be inserted using the \&'&\&' character.
  8521. Thus
  8522. .br
  8523.         'abc&{def}ghi'
  8524. .br
  8525. would produce
  8526. .br
  8527.         'abc   ghi'.
  8528. .br
  8529.  
  8530. You can access special symbols numerically by specifying \\character-code (in
  8531. octal), e.g., {/Symbol \\245} is the symbol for infinity.
  8532.  
  8533. You can escape control characters using \\, e.g.,  \\\\, \\{, and so on.
  8534.  
  8535. But be aware that strings in double-quotes are parsed differently than those
  8536. enclosed in single-quotes.  The major difference is that backslashes may need
  8537. to be doubled when in double-quoted strings.
  8538.  
  8539. Examples (these are hard to describe in words---try them!):
  8540. .br
  8541.       set xlabel 'Time (10^6 {/Symbol m}s)'
  8542. .br
  8543. .br
  8544.       set title '{/Symbol=18 \\362@_{/=9.6 0}^{/=12 x}} \\
  8545. .br
  8546. .br
  8547.                  {/Helvetica e^{-{/Symbol m}^2/2} d}{/Symbol m}'
  8548. .br
  8549.  
  8550. The file "ps_guide.ps" in the /docs/ps subdirectory of the \fBgnuplot\fR source
  8551. distribution contains more examples of the enhanced syntax.
  8552. .sp 2
  8553. .NH 4
  8554. Editing postscript
  8555. .sp 1
  8556. .LP
  8557. .XS
  8558. Editing postscript
  8559. .XE
  8560. The PostScript language is a very complex language---far too complex to
  8561. describe in any detail in this document.  Nevertheless there are some things
  8562. in a PostScript file written by \fBgnuplot\fR that can be changed without risk of
  8563. introducing fatal errors into the file.
  8564.  
  8565. For example, the PostScript statement "/Color true def" (written into the
  8566. file in response to the command \fBset terminal postscript color\fR), may be
  8567. altered in an obvious way to generate a black-and-white version of a plot.
  8568. Similarly line colors, text colors, line weights and symbol sizes can also be
  8569. altered in straight-forward ways.  Text (titles and labels) can be edited to
  8570. correct misspellings or to change fonts.  Anything can be repositioned, and
  8571. of course anything can be added or deleted, but modifications such as these
  8572. may require deeper knowledge of the PostScript language.
  8573.  
  8574. The organization of a PostScript file written by \fBgnuplot\fR is discussed in
  8575. the text file "ps_file.doc" in the /docs/ps subdirectory.
  8576. .sp 2
  8577. .RE
  8578. .br
  8579. .NH 3
  8580. Pslatex and pstex
  8581. .sp 1
  8582. .LP
  8583. .XS
  8584. Pslatex and pstex
  8585. .XE
  8586. The \fBpslatex\fR and \fBpstex\fR drivers generate output for further processing by
  8587. LaTeX and TeX, respectively.  Figures generated by \fBpstex\fR can be included
  8588. in any plain-based format (including LaTeX).
  8589.  
  8590. Syntax:
  8591. .br
  8592.       set terminal pslatex | |pstex {<color>} {<dashed>} {<rotate>}
  8593. .br
  8594. .br
  8595.                                     {auxfile} {<font_size>}
  8596. .br
  8597.  
  8598. <color> is either \fBcolor\fR or \fBmonochrome\fR.  <rotate> is either \fBrotate\fR or
  8599. \fBnorotate\fR and determines if the y-axis label is rotated.  <font_size> is
  8600. used to scale the font from its usual size.
  8601.  
  8602. If \fBauxfile\fR is specified, it directs the driver to put the PostScript
  8603. commands into an auxiliary file instead of directly into the LaTeX file.
  8604. This is useful if your pictures are large enough that dvips cannot handle
  8605. them.  The name of the auxiliary PostScript file is derived from the name of
  8606. the TeX file given on the \fBset output\fR command; it is determined by replacing
  8607. the trailing \fB.tex\fR (actually just the final extent in the file name) with
  8608. \fB.ps\fR in the output file name, or, if the TeX file has no extension, \fB.ps\fR
  8609. is appended.  Remember to close the file before leaving \fBgnuplot\fR.
  8610.  
  8611. All drivers for LaTeX offer a special way of controlling text positioning:
  8612. If any text string begins with \&'{\&', you also need to include a \&'}\&' at the
  8613. end of the text, and the whole text will be centered both horizontally
  8614. and vertically by LaTeX. --- If the text string begins with \&'[\&', you need
  8615. to continue it with: a position specification (up to two out of t,b,l,r),
  8616. \&\&']{\&', the text itself, and finally, \&'}\&'. The text itself may be anything
  8617. LaTeX can typeset as an LR-box. \\rule{}{}\&'s may help for best positioning.
  8618.  
  8619. Examples:
  8620. .br
  8621.       set term pslatex monochrome dashed rotate       # set to defaults
  8622. .br
  8623. To write the PostScript commands into the file "foo.ps":
  8624. .br
  8625.       set term pslatex auxfile
  8626. .br
  8627. .br
  8628.       set output "foo.tex"; plot ...: set output
  8629. .br
  8630. About label positioning:
  8631. Use gnuplot defaults (mostly sensible, but sometimes not really best):
  8632. .br
  8633.        set title '\\LaTeX\\ -- $ \\gamma $'
  8634. .br
  8635. Force centering both horizontally and vertically:
  8636. .br
  8637.        set label '{\\LaTeX\\ -- $ \\gamma $}' at 0,0
  8638. .br
  8639. Specify own positioning (top here):
  8640. .br
  8641.        set xlabel '[t]{\\LaTeX\\ -- $ \\gamma $}'
  8642. .br
  8643. The other label -- account for long ticlabels:
  8644. .br
  8645.        set ylabel '[r]{\\LaTeX\\ -- $ \\gamma $\\rule{7mm}{0pt}'
  8646. .br
  8647.  
  8648. Linewidths and pointsizes may be changed with \fBset linestyle\fR.
  8649. .sp 2
  8650. .NH 3
  8651. Pstricks
  8652. .sp 1
  8653. .LP
  8654. .XS
  8655. Pstricks
  8656. .XE
  8657. The \fBpstricks\fR driver is intended for use with the "pstricks.sty" macro
  8658. package for LaTeX.  It is an alternative to the \fBeepic\fR and \fBlatex\fR drivers.
  8659. You need "pstricks.sty", and, of course, a printer that understands
  8660. PostScript, or a converter such as Ghostscript.
  8661.  
  8662. PSTricks is available via anonymous ftp from the /pub directory at
  8663. Princeton.EDU.  This driver definitely does not come close to using the full
  8664. capability of the PSTricks package.
  8665.  
  8666. Syntax:
  8667. .br
  8668.       set terminal pstricks {hacktext | nohacktext} {unit | nounit}
  8669. .br
  8670.  
  8671. The first option invokes an ugly hack that gives nicer numbers; the second
  8672. has to do with plot scaling.  The defaults are \fBhacktext\fR and \fBnounit\fR.
  8673. .sp 2
  8674. .NH 3
  8675. Qms
  8676. .sp 1
  8677. .LP
  8678. .XS
  8679. Qms
  8680. .XE
  8681. The \fBqms\fR terminal driver supports the QMS/QUIC Laser printer, the Talaris
  8682. 1200 and others.  It has no options.
  8683. .sp 2
  8684. .NH 3
  8685. Regis
  8686. .sp 1
  8687. .LP
  8688. .XS
  8689. Regis
  8690. .XE
  8691. The \fBregis\fR terminal device generates output in the REGIS graphics language.
  8692. It has the option of using 4 (the default) or 16 colors.
  8693.  
  8694. Syntax:
  8695. .br
  8696.       set terminal regis {4 | 16}
  8697. .br
  8698. .sp 2
  8699. .NH 3
  8700. Rgip
  8701. .sp 1
  8702. .LP
  8703. .XS
  8704. Rgip
  8705. .XE
  8706. The \fBrgip\fR and \fBuniplex\fR terminal drivers support RGIP metafiles.  They can
  8707. combine several graphs on a single page, but only one page is allowed in a
  8708. given output file.
  8709.  
  8710. Syntax:
  8711. .br
  8712.       set terminal rgip | uniplex {portrait | landscape}
  8713. .br
  8714. .br
  8715.                                   {[<horiz>,<vert>]} {<fontsize>}
  8716. .br
  8717.  
  8718. permissible values for the font size are in the range 1--8, with the default
  8719. being 1.  The default layout is landscape.  Graphs are placed on the page in
  8720. a \fBhoriz\fRx\fBvert\fR grid, which defaults to [1,1].
  8721.  
  8722. Example:
  8723. .br
  8724.       set terminal uniplex portrait [2,3]
  8725. .br
  8726.  
  8727. puts six graphs on a page in three rows of two in portrait orientation.
  8728. .sp 2
  8729. .NH 3
  8730. Sun
  8731. .sp 1
  8732. .LP
  8733. .XS
  8734. Sun
  8735. .XE
  8736. The \fBsun\fR terminal driver supports the SunView window system.  It has no
  8737. options.
  8738. .sp 2
  8739. .NH 3
  8740. Tek410x
  8741. .sp 1
  8742. .LP
  8743. .XS
  8744. Tek410x
  8745. .XE
  8746. The \fBtek410x\fR terminal driver supports the 410x and 420x family of Tektronix
  8747. terminals.  It has no options.
  8748. .sp 2
  8749. .NH 3
  8750. Table
  8751. .sp 1
  8752. .LP
  8753. .XS
  8754. Table
  8755. .XE
  8756. Instead of producing a graph, the \fBtable\fR terminal prints out the points on
  8757. which a graph would be based, i.e., the results of processing the \fBplot\fR or
  8758. \fBsplot\fR command, in a multicolumn ASCII table of X Y {Z} R values.  The
  8759. character R takes on one of three values: "i" if the point is in the active
  8760. range, "o" if it is out-of-range, or "u" if it is undefined.  The data
  8761. format is determined by the format of the axis labels (see \fBset format\fR).
  8762.  
  8763. For those times when you want the numbers, you can display them on the
  8764. screen or save them to a file.  This can be useful if you want to generate
  8765. contours and then save them for further use, perhaps for plotting with
  8766. \fBplot\fR;  see \fBset contour\fR for an example.  The same method can be used to
  8767. save interpolated data (see \fBset samples\fR and \fBset dgrid3d\fR).
  8768. .sp 2
  8769. .NH 3
  8770. Tek40
  8771. .sp 1
  8772. .LP
  8773. .XS
  8774. Tek40
  8775. .XE
  8776. This family of terminal drivers supports a variety of VT-like terminals.
  8777. \fBtek40xx\fR supports Tektronix 4010 and others as well as most TEK emulators;
  8778. \fBvttek\fR supports VT-like tek40xx terminal emulators; \fBkc-tek40xx\fR supports
  8779. MS-DOS Kermit Tek4010 terminal emulators in color: \fBkm-tek40xx\fR supports them
  8780. in monochrome; \fBselanar\fR supports Selanar graphics; and \fBbitgraph\fR supports
  8781. BBN Bitgraph terminals.  None have any options.
  8782. .sp 2
  8783. .NH 3
  8784. Texdraw
  8785. .sp 1
  8786. .LP
  8787. .XS
  8788. Texdraw
  8789. .XE
  8790. The \fBtexdraw\fR terminal driver supports the LaTeX texdraw environment.  It is
  8791. intended for use with "texdraw.sty" and "texdraw.tex" in the texdraw package.
  8792.  
  8793. It has no options.
  8794. .sp 2
  8795. .NH 3
  8796. Tgif
  8797. .sp 1
  8798. .LP
  8799. .XS
  8800. Tgif
  8801. .XE
  8802. Tgif is an X11-based drawing tool---it has nothing to do with GIF.
  8803.  
  8804. The \fBtgif\fR driver supports different pointsizes (with \fBset pointsize\fR),
  8805. different label fonts and font sizes (e.g. \fBset label "Hallo" at x,y font
  8806. "Helvetica,34"\fR) and multiple graphs on the page.  The proportions of the
  8807. axes are not changed.
  8808.  
  8809. Syntax:
  8810. .br
  8811.       set terminal tgif {portrait | landscape} {<[x,y]>}
  8812. .br
  8813. .br
  8814.                         {solid | dashed}
  8815. .br
  8816. .br
  8817.                         {"<fontname>"} {<fontsize>}
  8818. .br
  8819.  
  8820. where <[x,y]> specifies the number of graphs in the x and y directions on the
  8821. page, "<fontname>" is the name of a valid PostScript font, and <fontsize>
  8822. specifies the size of the PostScript font.  Defaults are \fBportrait\fR, \fB[1,1]\fR,
  8823. \fBdashed\fR, \fB"Helvetica"\fR, and \fB18\fR.
  8824.  
  8825. The \fBsolid\fR option is usually prefered if lines are colored, as they often
  8826. are in the editor.  Hardcopy will be black-and-white, so \fBdashed\fR should be
  8827. chosen for that.
  8828.  
  8829. Multiplot is implemented in two different ways.
  8830.  
  8831. The first multiplot implementation is the standard gnuplot multiplot feature:
  8832.  
  8833. .br
  8834.       set terminal tgif
  8835. .br
  8836. .br
  8837.       set output "file.obj"
  8838. .br
  8839. .br
  8840.       set multiplot
  8841. .br
  8842. .br
  8843.       set origin x01,y01
  8844. .br
  8845. .br
  8846.       set size  xs,ys
  8847. .br
  8848. .br
  8849.       plot ...
  8850. .br
  8851. .br
  8852.            ...
  8853. .br
  8854. .br
  8855.       set origin x02,y02
  8856. .br
  8857. .br
  8858.       plot ...
  8859. .br
  8860. .br
  8861.       set nomultiplot
  8862. .br
  8863.  
  8864. See \fBset multiplot\fR for further information.
  8865.  
  8866. The second version is the [x,y] option for the driver itself.  The advantage
  8867. of this implementation is that everything is scaled and placed automatically
  8868. without the need for setting origins and sizes; the graphs keep their natural
  8869. x/y proportions of 3/2 (or whatever is fixed by \fBset size\fR).
  8870.  
  8871. If both multiplot methods are selected, the standard method is chosen and a
  8872. warning message is given.
  8873.  
  8874. Examples of single plots (or standard multiplot):
  8875. .br
  8876.       set terminal tgif                  # defaults
  8877. .br
  8878. .br
  8879.       set terminal tgif "Times-Roman" 24
  8880. .br
  8881. .br
  8882.       set terminal tgif landscape
  8883. .br
  8884. .br
  8885.       set terminal tgif landscape solid
  8886. .br
  8887.  
  8888. Examples using the built-in multiplot mechanism:
  8889. .br
  8890.       set terminal tgif portrait [2,4]  # portrait; 2 plots in the x-
  8891. .br
  8892. .br
  8893.                                         # and 4 in the y-direction
  8894. .br
  8895. .br
  8896.       set terminal tgif [1,2]           # portrait; 1 plot in the x-
  8897. .br
  8898. .br
  8899.                                         # and 2 in the y-direction
  8900. .br
  8901. .br
  8902.       set terminal tgif landscape [3,3] # landscape; 3 plots in both
  8903. .br
  8904. .br
  8905.                                         # directions
  8906. .br
  8907. .sp 2
  8908. .NH 3
  8909. Tkcanvas
  8910. .sp 1
  8911. .LP
  8912. .XS
  8913. Tkcanvas
  8914. .XE
  8915. This terminal driver generates Tk canvas widget commands based on Tcl/Tk
  8916. (default) or Perl.  To use it, rebuild \fBgnuplot\fR (after uncommenting or
  8917. inserting the appropriate line in "term.h"), then
  8918.  
  8919. .br
  8920.  gnuplot> set term tkcanvas {perltk} {interactive}
  8921. .br
  8922. .br
  8923.  gnuplot> set output 'plot.file'
  8924. .br
  8925.  
  8926. After invoking "wish", execute the following sequence of Tcl/Tk commands:
  8927.  
  8928. .br
  8929.  % source plot.file
  8930. .br
  8931. .br
  8932.  % canvas .c
  8933. .br
  8934. .br
  8935.  % pack .c
  8936. .br
  8937. .br
  8938.  % gnuplot .c
  8939. .br
  8940.  
  8941. Or, for Perl/Tk use a program like this:
  8942.  
  8943. .br
  8944.  use Tk;
  8945. .br
  8946. .br
  8947.  my $top = MainWindow->new;
  8948. .br
  8949. .br
  8950.  my $c = $top->Canvas;
  8951. .br
  8952. .br
  8953.  $c->pack();
  8954. .br
  8955. .br
  8956.  do "plot.pl";
  8957. .br
  8958. .br
  8959.  gnuplot->($c);
  8960. .br
  8961. .br
  8962.  MainLoop;
  8963. .br
  8964.  
  8965. The code generated by \fBgnuplot\fR creates a procedure called "gnuplot"
  8966. that takes the name of a canvas as its argument.  When the procedure is
  8967. called, it clears the canvas, finds the size of the canvas and draws the plot
  8968. in it, scaled to fit.
  8969.  
  8970. For 2-dimensional plotting (\fBplot\fR) two additional procedures are defined:
  8971. "gnuplot_plotarea" will return a list containing the borders of the plotting
  8972. area "xleft, xright, ytop, ybot" in canvas screen coordinates, while the ranges
  8973. of the two axes "x1min, x1max, y1min, y1max, x2min, x2max, y2min, y2max" in plot
  8974. coordinates can be obtained calling "gnuplot_axisranges".
  8975. If the "interactive" option is specified, mouse clicking on a line segment
  8976. will print the coordinates of its midpoint to stdout. Advanced actions
  8977. can happen instead if the user supplies a procedure named
  8978. "user_gnuplot_coordinates", which takes the following arguments:
  8979. "win id x1s y1s x2s y2s x1e y1e x2e y2e x1m y1m x2m y2m",
  8980. the name of the canvas and the id of the line segment followed by the
  8981. coordinates of its start and end point in the two possible axis ranges; the
  8982. coordinates of the midpoint are only filled for logarithmic axes.
  8983.  
  8984. The current version of \fBtkcanvas\fR supports neither \fBmultiplot\fR nor \fBreplot\fR.
  8985. .sp 2
  8986. .NH 3
  8987. Tpic
  8988. .sp 1
  8989. .LP
  8990. .XS
  8991. Tpic
  8992. .XE
  8993. The \fBtpic\fR terminal driver supports the LaTeX picture environment with tpic
  8994. \\specials.  It is an alternative to the \fBlatex\fR and \fBeepic\fR terminal drivers.
  8995. Options are the point size, line width, and dot-dash interval.
  8996.  
  8997. Syntax:
  8998. .br
  8999.       set terminal tpic <pointsize> <linewidth> <interval>
  9000. .br
  9001.  
  9002. where \fBpointsize\fR and \fBlinewidth\fR are integers in milli-inches and \fBinterval\fR
  9003. is a float in inches.  If a non-positive value is specified, the default is
  9004. chosen: pointsize = 40, linewidth = 6, interval = 0.1.
  9005.  
  9006. All drivers for LaTeX offer a special way of controlling text positioning:
  9007. If any text string begins with \&'{\&', you also need to include a \&'}\&' at the
  9008. end of the text, and the whole text will be centered both horizontally
  9009. and vertically by LaTeX. --- If the text string begins with \&'[\&', you need
  9010. to continue it with: a position specification (up to two out of t,b,l,r),
  9011. \&\&']{\&', the text itself, and finally, \&'}\&'. The text itself may be anything
  9012. LaTeX can typeset as an LR-box. \\rule{}{}\&'s may help for best positioning.
  9013.  
  9014. Examples:
  9015. About label positioning:
  9016. Use gnuplot defaults (mostly sensible, but sometimes not really best):
  9017. .br
  9018.        set title '\\LaTeX\\ -- $ \\gamma $'
  9019. .br
  9020. Force centering both horizontally and vertically:
  9021. .br
  9022.        set label '{\\LaTeX\\ -- $ \\gamma $}' at 0,0
  9023. .br
  9024. Specify own positioning (top here):
  9025. .br
  9026.        set xlabel '[t]{\\LaTeX\\ -- $ \\gamma $}'
  9027. .br
  9028. The other label -- account for long ticlabels:
  9029. .br
  9030.        set ylabel '[r]{\\LaTeX\\ -- $ \\gamma $\\rule{7mm}{0pt}'
  9031. .br
  9032. .sp 2
  9033. .NH 3
  9034. Unixpc
  9035. .sp 1
  9036. .LP
  9037. .XS
  9038. Unixpc
  9039. .XE
  9040. The \fBunixpc\fR terminal driver supports AT&T 3b1 and AT&T 7300 Unix PC.  It has
  9041. no options.
  9042. .sp 2
  9043. .NH 3
  9044. Unixplot
  9045. .sp 1
  9046. .LP
  9047. .XS
  9048. Unixplot
  9049. .XE
  9050. The \fBunixplot\fR terminal driver generates output in the Unix "plot" graphics
  9051. language.  It has no options.
  9052.  
  9053. This terminal cannot be compiled if the GNU version of plot is to be used;
  9054. in that case, use the \fBgnugraph\fR terminal instead.
  9055. .sp 2
  9056. .NH 3
  9057. Vx384
  9058. .sp 1
  9059. .LP
  9060. .XS
  9061. Vx384
  9062. .XE
  9063. The \fBvx384\fR terminal driver supports the Vectrix 384 and Tandy color
  9064. printers.  It has no options.
  9065. .sp 2
  9066. .NH 3
  9067. VWS
  9068. .sp 1
  9069. .LP
  9070. .XS
  9071. VWS
  9072. .XE
  9073. The \fBVWS\fR terminal driver supports the VAX Windowing System.  It has
  9074. no options.  It will sense the display type (monochrome, gray scale,
  9075. or color.)  All line styles are plotted as solid lines.
  9076. .sp 2
  9077. .NH 3
  9078. Windows
  9079. .sp 1
  9080. .LP
  9081. .XS
  9082. Windows
  9083. .XE
  9084. Three options may be set in the \fBwindows\fR terminal driver.
  9085.  
  9086. Syntax:
  9087. .br
  9088.       set terminal windows {<color>} {"<fontname>"} {<fontsize>}
  9089. .br
  9090.  
  9091. where \fB<color>\fR is either \fBcolor\fR or \fBmonochrome\fR, \fB"<fontname>"\fR is the
  9092. name of a valid Windows font, and \fB<fontsize>\fR is the size of the font in
  9093. points.
  9094.  
  9095. Other options may be set with the graph-menu, the initialization file,
  9096. and \fBset linestyle\fR.
  9097.  
  9098. The Windows version normally terminates immediately as soon as the end of
  9099. any files given as command line arguments is reached (i.e. in non-interactive
  9100. mode). It will also not show the text-window at all, in this mode, only
  9101. the plot. By giving the optional argument
  9102. \fB/noend\fR or \fB-noend\fR, you can disable this behaviour.
  9103. .sp 2
  9104. .RS
  9105. .IP
  9106. .NH 4
  9107. Graph-menu
  9108. .sp 1
  9109. .LP
  9110. .XS
  9111. Graph-menu
  9112. .XE
  9113. The \fBgnuplot graph\fR window has the following options on a pop-up menu
  9114. accessed by pressing the right mouse button or selecting \fBOptions\fR from the
  9115. system menu:
  9116.  
  9117. \fBBring to Top\fR when checked brings the graph window to the top after every
  9118. plot.
  9119.  
  9120. \fBColor\fR when checked enables color linestyles.  When unchecked it forces
  9121. monochrome linestyles.
  9122.  
  9123. \fBCopy to Clipboard\fR copies a bitmap and a Metafile picture.
  9124.  
  9125. \fBBackground...\fR sets the window background color.
  9126.  
  9127. \fBChoose Font...\fR selects the font used in the graphics window.
  9128.  
  9129. \fBLine Styles...\fR allows customization of the line colors and styles.
  9130.  
  9131. \fBPrint...\fR prints the graphics windows using a Windows printer driver and
  9132. allows selection of the printer and scaling of the output.  The output
  9133. produced by \fBPrint\fR is not as good as that from \fBgnuplot\fR\&'s own printer
  9134. drivers.
  9135.  
  9136. \fBUpdate wgnuplot.ini\fR saves the current window locations, window sizes, text
  9137. window font, text window font size, graph window font, graph window font
  9138. size, background color and linestyles to the initialization file
  9139. \fBWGNUPLOT.INI\fR.
  9140. .sp 2
  9141. .NH 4
  9142. Printing
  9143. .sp 1
  9144. .LP
  9145. .XS
  9146. Printing
  9147. .XE
  9148. In order of preference, graphs may be be printed in the following ways.
  9149.  
  9150. \fB1.\fR Use the \fBgnuplot\fR command \fBset terminal\fR to select a printer and \fBset
  9151. output\fR to redirect output to a file.
  9152.  
  9153. \fB2.\fR Select the \fBPrint...\fR command from the \fBgnuplot graph\fR window.  An extra
  9154. command \fBscreendump\fR does this from the text window.
  9155.  
  9156. \fB3.\fR If \fBset output "PRN"\fR is used, output will go to a temporary file.  When
  9157. you exit from \fBgnuplot\fR or when you change the output with another \fBset
  9158. output\fR command, a dialog box will appear for you to select a printer port.
  9159. If you choose OK, the output will be printed on the selected port, passing
  9160. unmodified through the print manager.  It is possible to accidentally (or
  9161. deliberately) send printer output meant for one printer to an incompatible
  9162. printer.
  9163. .sp 2
  9164. .NH 4
  9165. Text-menu
  9166. .sp 1
  9167. .LP
  9168. .XS
  9169. Text-menu
  9170. .XE
  9171. The \fBgnuplot text\fR window has the following options on a pop-up menu accessed
  9172. by pressing the right mouse button or selecting \fBOptions\fR from the system
  9173. menu:
  9174.  
  9175. \fBCopy to Clipboard\fR copies marked text to the clipboard.
  9176.  
  9177. \fBPaste\fR copies text from the clipboard as if typed by the user.
  9178.  
  9179. \fBChoose Font...\fR selects the font used in the text window.
  9180.  
  9181. \fBSystem Colors\fR when selected makes the text window honor the System Colors
  9182. set using the Control Panel.  When unselected, text is black or blue on a
  9183. white background.
  9184.  
  9185. \fBUpdate wgnuplot.ini\fR saves the current text window location, text window
  9186. size, text window font and text window font size to the initialisation file
  9187. \fBWGNUPLOT.INI\fR.
  9188.  
  9189. \fBMENU BAR\fR
  9190.  
  9191. If the menu file \fBWGNUPLOT.MNU\fR is found in the same directory as
  9192. WGNUPLOT.EXE, then the menu specified in \fBWGNUPLOT.MNU\fR will be loaded.
  9193. Menu commands:
  9194.  
  9195. [Menu] starts a new menu with the name on the following line.
  9196.  
  9197. [EndMenu] ends the current menu.
  9198.  
  9199. [--] inserts a horizontal menu separator.
  9200.  
  9201. [|] inserts a vertical menu separator.
  9202.  
  9203. [Button] puts the next macro on a push button instead of a menu.
  9204.  
  9205. Macros take two lines with the macro name (menu entry) on the first line and
  9206. the macro on the second line.  Leading spaces are ignored.  Macro commands:
  9207.  
  9208. [INPUT] --- Input string with prompt terminated by [EOS] or {ENTER}
  9209.  
  9210. [EOS] --- End Of String terminator.  Generates no output.
  9211.  
  9212. [OPEN] --- Get name of file to open from list box, with title of list box
  9213. terminated by [EOS], followed by default filename terminated by [EOS] or
  9214. {ENTER}.  This uses COMMDLG.DLL from Windows 3.1.
  9215.  
  9216. [SAVE] --- Get name of file to save.  Similar to [OPEN]
  9217.  
  9218. Macro character substitutions:
  9219.  
  9220. {ENTER} --- Carriage Return \&'\\r\&'
  9221.  
  9222. {TAB} --- Tab \&'\\011\&'
  9223.  
  9224. {ESC} --- Escape \&'\\033\&'
  9225.  
  9226. {^A} --- \&'\\001\&'
  9227.  
  9228. \&...
  9229.  
  9230. {^_} --- \&'\\031\&'
  9231.  
  9232. Macros are limited to 256 characters after expansion.
  9233. .sp 2
  9234. .NH 4
  9235. Wgnuplot.ini
  9236. .sp 1
  9237. .LP
  9238. .XS
  9239. Wgnuplot.ini
  9240. .XE
  9241. Windows \fBgnuplot\fR will read some of its options from the \fB[WGNUPLOT]\fR section
  9242. of \fBWGNUPLOT.INI\fR in the Windows directory.  A sample \fBWGNUPLOT.INI\fR file:
  9243.  
  9244. .br
  9245.       [WGNUPLOT]
  9246. .br
  9247. .br
  9248.       TextOrigin=0 0
  9249. .br
  9250. .br
  9251.       TextSize=640 150
  9252. .br
  9253. .br
  9254.       TextFont=Terminal,9
  9255. .br
  9256. .br
  9257.       GraphOrigin=0 150
  9258. .br
  9259. .br
  9260.       GraphSize=640 330
  9261. .br
  9262. .br
  9263.       GraphFont=Arial,10
  9264. .br
  9265. .br
  9266.       GraphColor=1
  9267. .br
  9268. .br
  9269.       GraphToTop=1
  9270. .br
  9271. .br
  9272.       GraphBackground=255 255 255
  9273. .br
  9274. .br
  9275.       Border=0 0 0 0 0
  9276. .br
  9277. .br
  9278.       Axis=192 192 192 2 2
  9279. .br
  9280. .br
  9281.       Line1=0 0 255 0 0
  9282. .br
  9283. .br
  9284.       Line2=0 255 0 0 1
  9285. .br
  9286. .br
  9287.       Line3=255 0 0 0 2
  9288. .br
  9289. .br
  9290.       Line4=255 0 255 0 3
  9291. .br
  9292. .br
  9293.       Line5=0 0 128 0 4
  9294. .br
  9295.  
  9296. The \fBGraphFont\fR entry specifies the font name and size in points.  The five
  9297. numbers given in the \fBBorder\fR, \fBAxis\fR and \fBLine\fR entries are the \fBRed\fR
  9298. intensity (0--255), \fBGreen\fR intensity, \fBBlue\fR intensity, \fBColor Linestyle\fR
  9299. and \fBMono Linestyle\fR.  \fBLinestyles\fR are 0=SOLID, 1=DASH, 2=DOT, 3=DASHDOT,
  9300. 4=DASHDOTDOT.  In the sample \fBWGNUPLOT.INI\fR file above, Line 2 is a green
  9301. solid line in color mode, or a dashed line in monochrome mode.  The default
  9302. line width is 1 pixel.  If \fBLinestyle\fR is negative, it specifies the width of
  9303. a SOLID line in pixels.  Line1 and any linestyle used with the \fBpoints\fR style
  9304. must be SOLID with unit width.
  9305. .sp 2
  9306. .NH 4
  9307. Windows3.0
  9308. .sp 1
  9309. .LP
  9310. .XS
  9311. Windows3.0
  9312. .XE
  9313. Windows 3.1 is preferred, but WGNUPLOT will run under Windows 3.0 with the
  9314. following restrictions:
  9315. \fB1.\fR COMMDLG.DLL and SHELL.DLL (available with Windows 3.1 or Borland C++
  9316. 3.1) must be in the windows directory.
  9317.  
  9318. \fB2.\fR WGNUPLOT.HLP produced by Borland C++ 3.1 is in Windows 3.1 format.
  9319. You need to use the WINHELP.EXE supplied with Borland C++ 3.1.
  9320.  
  9321. \fB3.\fR It will not run in real mode due to lack of memory.
  9322.  
  9323. \fB4.\fR TrueType fonts are not available in the graph window.
  9324.  
  9325. \fB5.\fR Drag-drop does not work.
  9326. .sp 2
  9327. .RE
  9328. .br
  9329. .NH 3
  9330. X11
  9331. .sp 1
  9332. .LP
  9333. .XS
  9334. X11
  9335. .XE
  9336. \fBgnuplot\fR provides the \fBx11\fR terminal type for use with X servers.  This
  9337. terminal type is set automatically at startup if the \fBDISPLAY\fR environment
  9338. variable is set, if the \fBTERM\fR environment variable is set to \fBxterm\fR, or
  9339. if the \fB-display\fR command line option is used.
  9340.  
  9341. Syntax:
  9342. .br
  9343.       set terminal x11 {reset} {<n>}
  9344. .br
  9345.  
  9346. Multiple plot windows are supported: \fBset terminal x11 <n>\fR directs the
  9347. output to plot window number n.  If n>0, the terminal number will be
  9348. appended to the window title and the icon will be labeled \fBgplt <n>\fR.
  9349. The active window may distinguished by a change in cursor (from default
  9350. to crosshair.)
  9351.  
  9352. Plot windows remain open even when the \fBgnuplot\fR driver is changed to a
  9353. different device.  A plot window can be closed by pressing the letter q
  9354. while that window has input focus, or by choosing \fBclose\fR from a window
  9355. manager menu.  All plot windows can be closed by specifying \fBreset\fR, which
  9356. actually terminates the subprocess which maintains the windows (unless
  9357. \fB-persist\fR was specified).
  9358.  
  9359. Plot windows will automatically be closed at the end of the session
  9360. unless the \fB-persist\fR option was given.
  9361.  
  9362. The size or aspect ratio of a plot may be changed by resizing the \fBgnuplot\fR
  9363. window.
  9364.  
  9365. Linewidths and pointsizes may be changed from within \fBgnuplot\fR with
  9366. \fBset linestyle\fR.
  9367.  
  9368. For terminal type \fBx11\fR, \fBgnuplot\fR accepts (when initialized) the standard
  9369. X Toolkit options and resources such as geometry, font, and name from the
  9370. command line arguments or a configuration file.  See the X(1) man page
  9371. (or its equivalent) for a description of such options.
  9372.  
  9373. A number of other \fBgnuplot\fR options are available for the \fBx11\fR terminal.
  9374. These may be specified either as command-line options when \fBgnuplot\fR is
  9375. invoked or as resources in the configuration file "/.Xdefaults".  They are
  9376. set upon initialization and cannot be altered during a \fBgnuplot\fR session.
  9377. .sp 2
  9378. .RS
  9379. .IP
  9380. .NH 4
  9381. Command-line_options
  9382. .sp 1
  9383. .LP
  9384. .XS
  9385. Command-line_options
  9386. .XE
  9387. In addition to the X Toolkit options, the following options may be specified
  9388. on the command line when starting \fBgnuplot\fR or as resources in your
  9389. ".Xdefaults" file:
  9390.  
  9391. .EQ
  9392. delim $$
  9393. .EN
  9394. .KS
  9395. .TS
  9396. center box tab (@) ;
  9397. c l .
  9398. `-mono`@forces monochrome rendering on color displays.
  9399. `-gray`@requests grayscale rendering on grayscale or color displays.
  9400.        @(Grayscale displays receive monochrome rendering by default.)
  9401. `-clear`@requests that the window be cleared momentarily before a
  9402.         @new plot is displayed.
  9403. `-tvtwm`@requests that geometry specifications for position of the
  9404.         @window be made relative to the currently displayed portion
  9405.         @of the virtual root.
  9406. `-raise`@raise plot window after each plot
  9407. `-noraise`@do not raise plot window after each plot
  9408. `-persist`@plot windows survive after main gnuplot program exits
  9409. .TE
  9410. .KE
  9411. .EQ
  9412. delim off
  9413. .EN
  9414.  
  9415. The options are shown above in their command-line syntax.  When entered as
  9416. resources in ".Xdefaults", they require a different syntax.
  9417.  
  9418. Example:
  9419. .br
  9420.       gnuplot*gray: on
  9421. .br
  9422.  
  9423. \fBgnuplot\fR also provides a command line option (\fB-pointsize <v>\fR) and a
  9424. resource, \fBgnuplot*pointsize: <v>\fR, to control the size of points plotted
  9425. with the \fBpoints\fR plotting style.  The value \fBv\fR is a real number (greater
  9426. than 0 and less than or equal to ten) used as a scaling factor for point
  9427. sizes.  For example, \fB-pointsize 2\fR uses points twice the default size, and
  9428. \fB-pointsize 0.5\fR uses points half the normal size.
  9429. .sp 2
  9430. .NH 4
  9431. Monochome_options
  9432. .sp 1
  9433. .LP
  9434. .XS
  9435. Monochome_options
  9436. .XE
  9437. For monochrome displays, \fBgnuplot\fR does not honor foreground or background
  9438. colors.  The default is black-on-white.  \fB-rv\fR or \fBgnuplot*reverseVideo: on\fR
  9439. requests white-on-black.
  9440.  
  9441. .sp 2
  9442. .NH 4
  9443. Color_resources
  9444. .sp 1
  9445. .LP
  9446. .XS
  9447. Color_resources
  9448. .XE
  9449. For color displays, \fBgnuplot\fR honors the following resources (shown here
  9450. with their default values) or the greyscale resources.  The values may be
  9451. color names as listed in the X11 rgb.txt file on your system, hexadecimal
  9452. RGB color specifications (see X11 documentation), or a color name followed
  9453. by a comma and an \fBintensity\fR value from 0 to 1.  For example, \fBblue, 0.5\fR
  9454. means a half intensity blue.
  9455.  
  9456. .EQ
  9457. delim $$
  9458. .EN
  9459. .KS
  9460. .TS
  9461. center box tab (@) ;
  9462. c l .
  9463. @gnuplot*background: white
  9464. @gnuplot*textColor: black
  9465. @gnuplot*borderColor: black
  9466. @gnuplot*axisColor: black
  9467. @gnuplot*line1Color: red
  9468. @gnuplot*line2Color: green
  9469. @gnuplot*line3Color: blue
  9470. @gnuplot*line4Color: magenta
  9471. @gnuplot*line5Color: cyan
  9472. @gnuplot*line6Color: sienna
  9473. @gnuplot*line7Color: orange
  9474. @gnuplot*line8Color: coral
  9475. .TE
  9476. .KE
  9477. .EQ
  9478. delim off
  9479. .EN
  9480.  
  9481.  
  9482. The command-line syntax for these is, for example,
  9483.  
  9484. Example:
  9485. .br
  9486.       gnuplot -background coral
  9487. .br
  9488.  
  9489. .sp 2
  9490. .NH 4
  9491. Grayscale_resources
  9492. .sp 1
  9493. .LP
  9494. .XS
  9495. Grayscale_resources
  9496. .XE
  9497. When \fB-gray\fR is selected, \fBgnuplot\fR honors the following resources for
  9498. grayscale or color displays (shown here with their default values).  Note
  9499. that the default background is black.
  9500.  
  9501. .EQ
  9502. delim $$
  9503. .EN
  9504. .KS
  9505. .TS
  9506. center box tab (@) ;
  9507. c l .
  9508. @gnuplot*background: black
  9509. @gnuplot*textGray: white
  9510. @gnuplot*borderGray: gray50
  9511. @gnuplot*axisGray: gray50
  9512. @gnuplot*line1Gray: gray100
  9513. @gnuplot*line2Gray: gray60
  9514. @gnuplot*line3Gray: gray80
  9515. @gnuplot*line4Gray: gray40
  9516. @gnuplot*line5Gray: gray90
  9517. @gnuplot*line6Gray: gray50
  9518. @gnuplot*line7Gray: gray70
  9519. @gnuplot*line8Gray: gray30
  9520. .TE
  9521. .KE
  9522. .EQ
  9523. delim off
  9524. .EN
  9525.  
  9526.  
  9527. .sp 2
  9528. .NH 4
  9529. Line_resources
  9530. .sp 1
  9531. .LP
  9532. .XS
  9533. Line_resources
  9534. .XE
  9535. \fBgnuplot\fR honors the following resources for setting the width (in pixels) of
  9536. plot lines (shown here with their default values.)  0 or 1 means a minimal
  9537. width line of 1 pixel width.  A value of 2 or 3 may improve the appearance of
  9538. some plots.
  9539.  
  9540. .EQ
  9541. delim $$
  9542. .EN
  9543. .KS
  9544. .TS
  9545. center box tab (@) ;
  9546. c l .
  9547. @gnuplot*borderWidth: 2
  9548. @gnuplot*axisWidth: 0
  9549. @gnuplot*line1Width: 0
  9550. @gnuplot*line2Width: 0
  9551. @gnuplot*line3Width: 0
  9552. @gnuplot*line4Width: 0
  9553. @gnuplot*line5Width: 0
  9554. @gnuplot*line6Width: 0
  9555. @gnuplot*line7Width: 0
  9556. @gnuplot*line8Width: 0
  9557. .TE
  9558. .KE
  9559. .EQ
  9560. delim off
  9561. .EN
  9562.  
  9563.  
  9564. \fBgnuplot\fR honors the following resources for setting the dash style used for
  9565. plotting lines.  0 means a solid line.  A two-digit number \fBjk\fR (\fBj\fR and \fBk\fR
  9566. are >= 1  and <= 9) means a dashed line with a repeated pattern of \fBj\fR pixels
  9567. on followed by \fBk\fR pixels off.  For example, \&'16\&' is a "dotted" line with one
  9568. pixel on followed by six pixels off.  More elaborate on/off patterns can be
  9569. specified with a four-digit value.  For example, \&'4441\&' is four on, four off,
  9570. four on, one off.  The default values shown below are for monochrome displays
  9571. or monochrome rendering on color or grayscale displays.  For color displays,
  9572. the default for each is 0 (solid line) except for \fBaxisDashes\fR which defaults
  9573. to a \&'16\&' dotted line.
  9574.  
  9575. .EQ
  9576. delim $$
  9577. .EN
  9578. .KS
  9579. .TS
  9580. center box tab (@) ;
  9581. c l .
  9582. @gnuplot*borderDashes: 0
  9583. @gnuplot*axisDashes: 16
  9584. @gnuplot*line1Dashes: 0
  9585. @gnuplot*line2Dashes: 42
  9586. @gnuplot*line3Dashes: 13
  9587. @gnuplot*line4Dashes: 44
  9588. @gnuplot*line5Dashes: 15
  9589. @gnuplot*line6Dashes: 4441
  9590. @gnuplot*line7Dashes: 42
  9591. @gnuplot*line8Dashes: 13
  9592. .TE
  9593. .KE
  9594. .EQ
  9595. delim off
  9596. .EN
  9597.  
  9598. .sp 2
  9599. .RE
  9600. .br
  9601. .NH 3
  9602. Xlib
  9603. .sp 1
  9604. .LP
  9605. .XS
  9606. Xlib
  9607. .XE
  9608. The \fBxlib\fR terminal driver supports the X11 Windows System.  It generates
  9609. gnulib_x11 commands.  \fBset term x11\fR behaves similarly to \fBset terminal xlib;
  9610. set output "|gnuplot_x11"\fR.  \fBxlib\fR has no options, but see \fBx11\fR.
  9611. .sp 2
  9612. .RE
  9613. .br
  9614. .NH 2
  9615. Tics
  9616. .sp 1
  9617. .LP
  9618. .XS
  9619. Tics
  9620. .XE
  9621. The \fBset tics\fR command can be used to change the tics to be drawn outwards.
  9622.  
  9623. Syntax:
  9624. .br
  9625.       set tics {<direction>}
  9626. .br
  9627. .br
  9628.       show tics
  9629. .br
  9630.  
  9631. where <direction> may be \fBin\fR (the default) or \fBout\fR.
  9632.  
  9633. See also \fBset xtics\fR for more control of major (labelled) tic marks and \fBset
  9634. mxtics\fR for control of minor tic marks.
  9635. .sp 2
  9636. .NH 2
  9637. Ticslevel
  9638. .sp 1
  9639. .LP
  9640. .XS
  9641. Ticslevel
  9642. .XE
  9643. Using \fBsplot\fR, one can adjust the relative height of the vertical (Z) axis
  9644. using \fBset ticslevel\fR.  The numeric argument provided specifies the location
  9645. of the bottom of the scale (as a fraction of the z-range) above the xy-plane.
  9646. The default value is 0.5.  Negative values are permitted, but tic labels on
  9647. the three axes may overlap.
  9648.  
  9649. To place the xy-plane at a position \&'pos\&' on the z-axis, \fBticslevel\fR should
  9650. be set equal to  (pos - zmin) / (zmin - zmax).
  9651.  
  9652. Syntax:
  9653. .br
  9654.       set ticslevel {<level>}
  9655. .br
  9656. .br
  9657.       show tics
  9658. .br
  9659.  
  9660. See also \fBset view\fR.
  9661. .sp 2
  9662. .NH 2
  9663. Ticscale
  9664. .sp 1
  9665. .LP
  9666. .XS
  9667. Ticscale
  9668. .XE
  9669. The size of the tic marks can be adjusted with \fBset ticscale\fR.
  9670.  
  9671. Syntax:
  9672. .br
  9673.       set ticscale {<major> {<minor>}}
  9674. .br
  9675. .br
  9676.       show tics
  9677. .br
  9678.  
  9679. If <minor> is not specified, it is 0.5*<major>.  The default size is 1.0 for
  9680. major tics and 0.5 for minor tics.  Note that it is possible to have the tic
  9681. marks pointing outward by specifying a negative size.
  9682. .sp 2
  9683. .NH 2
  9684. Timestamp
  9685. .sp 1
  9686. .LP
  9687. .XS
  9688. Timestamp
  9689. .XE
  9690. The command \fBset timestamp\fR places the time and date of the plot in the left
  9691. margin.
  9692.  
  9693. Syntax:
  9694. .br
  9695.       set timestamp {"<format>"} {top|bottom} {{no}rotate}
  9696. .br
  9697. .br
  9698.                     {<xoff>}{,<yoff>} {"<font>"}
  9699. .br
  9700. .br
  9701.       set notimestamp
  9702. .br
  9703. .br
  9704.       show timestamp
  9705. .br
  9706.  
  9707. The format string allows you to choose the format used to write the date and
  9708. time.  Its default value is what asctime() uses: "%a %b %d %H:%M:%S %Y"
  9709. (weekday, month name, day of the month, hours, minutes, seconds, four-digit
  9710. year).  With \fBtop\fR or \fBbottom\fR you can place the timestamp at the top or
  9711. bottom of the left margin (default: bottom).  \fBrotate\fR lets you write the
  9712. timestamp vertically, if your terminal supports vertical text.  The constants
  9713. <xoff> and <off> are offsets from the default position given in character
  9714. screen coordinates.  <font> is used to specify the font with which the time
  9715. is to be written.
  9716.  
  9717. The abbreviation \fBtime\fR may be used in place of \fBtimestamp\fR.
  9718.  
  9719. Example:
  9720. .br
  9721.       set timestamp "%d/%m/%y %H:%M" 80,-2 "Helvetica"
  9722. .br
  9723.  
  9724. See \fBset timefmt\fR for more information about time format strings.
  9725. .sp 2
  9726. .NH 2
  9727. Timefmt
  9728. .sp 1
  9729. .LP
  9730. .XS
  9731. Timefmt
  9732. .XE
  9733. This command applies to timeseries where data are composed of dates/times.
  9734. It has no meaning unless the command \fBset xdata time\fR is given also.
  9735.  
  9736. Syntax:
  9737. .br
  9738.       set timefmt "<format string>"
  9739. .br
  9740. .br
  9741.       show timefmt
  9742. .br
  9743.  
  9744. The string argument tells \fBgnuplot\fR how to read timedata from the datafile.
  9745. The valid formats are:
  9746.  
  9747.  
  9748. .EQ
  9749. delim $$
  9750. .EN
  9751. .KS
  9752. .TS
  9753. center box tab (@) ;
  9754. c l .
  9755. Format@Explanation
  9756. _
  9757. %d@day of the month, 1--31
  9758. %m@month of the year, 1--12
  9759. %y@year, 0--99
  9760. %Y@year, 4-digit
  9761. %j@day of the year, 1--365
  9762. %H@hour, 0--24
  9763. %M@minute, 0--60
  9764. %S@second, 0--60
  9765. %b@three-character abbreviation of the name of the month
  9766. %B@name of the month
  9767. _
  9768. .TE
  9769. .KE
  9770. .EQ
  9771. delim off
  9772. .EN
  9773.  
  9774. Any character is allowed in the string, but must match exactly.  \\t (tab) is
  9775. recognized.  Backslash-octals (\\nnn) are converted to char.  If there is no
  9776. separating character between the time/date elements, then %d, %m, %y, %H, %M
  9777. and %S read two digits each, %Y reads four digits and %j reads three digits.
  9778. %b requires three characters, and %B requires as many as it needs.
  9779.  
  9780. Spaces are treated slightly differently.  A space in the string stands for
  9781. zero or more whitespace characters in the file.  That is, "%H %M" can be used
  9782. to read "1220" and "12     20" as well as "12 20".
  9783.  
  9784. Each set of non-blank characters in the timedata counts as one column in the
  9785. \fBusing n:n\fR specification.  Thus \fB11:11  25/12/76  21.0\fR consists of three
  9786. columns.  To avoid confusion, \fBgnuplot\fR requires that you provide a complete
  9787. \fBusing\fR specification if your file contains timedata.
  9788.  
  9789. Since \fBgnuplot\fR cannot read non-numerical text, if the date format includes
  9790. the day or month in words, the format string must exclude this text.  But
  9791. it can still be printed with the "%a", "%A", "%b", or "%B" specifier: see
  9792. \fBset format\fR for more details about these and other options for printing
  9793. timedata.  (\fBgnuplot\fR will determine the proper month and weekday from the
  9794. numerical values.)
  9795.  
  9796. See also \fBset xdata\fR and \fBTime/date\fR for more information.
  9797.  
  9798. Example:
  9799. .br
  9800.       set timefmt "%d/%m/%Y\\t%H:%M"
  9801. .br
  9802. tells \fBgnuplot\fR to read date and time separated by tab.  (But look closely at
  9803. your data---what began as a tab may have been converted to spaces somewhere
  9804. along the line; the format string must match what is actually in the file.)
  9805. .sp 2
  9806. .NH 2
  9807. Title
  9808. .sp 1
  9809. .LP
  9810. .XS
  9811. Title
  9812. .XE
  9813. The \fBset title\fR command produces a plot title that is centered at the top of
  9814. the plot.  \fBset title\fR is a special case of \fBset label\fR.
  9815.  
  9816. Syntax:
  9817. .br
  9818.       set title {"<title-text>"} {<xoff>}{,<yoff>} {"<font>,{<size>}"}
  9819. .br
  9820. .br
  9821.       show title
  9822. .br
  9823.  
  9824. Specifying constants <xoff> or <yoff> as optional offsets for the title will
  9825. move the title <xoff> or <yoff> character screen coordinates (not graph
  9826. coordinates).  For example, "\fBset title ,-1\fR" will change only the y offset
  9827. of the title, moving the title down by roughly the height of one character.
  9828.  
  9829. <font> is used to specify the font with which the title is to be written;
  9830. the units of the font <size> depend upon which terminal is used.
  9831.  
  9832. \fBset title\fR with no parameters clears the title.
  9833.  
  9834. See \fBsyntax\fR for details about the processing of backslash sequences and
  9835. the distinction between single- and double-quotes.
  9836. .sp 2
  9837. .NH 2
  9838. Tmargin
  9839. .sp 1
  9840. .LP
  9841. .XS
  9842. Tmargin
  9843. .XE
  9844. The command \fBset tmargin\fR sets the size of the top margin.  Please see
  9845. \fBset margin\fR for details.
  9846. .sp 2
  9847. .NH 2
  9848. Trange
  9849. .sp 1
  9850. .LP
  9851. .XS
  9852. Trange
  9853. .XE
  9854. The \fBset trange\fR command sets the parametric range used to compute x and y
  9855. values when in parametric or polar modes.  Please see \fBset xrange\fR for
  9856. details.
  9857. .sp 2
  9858. .NH 2
  9859. Urange
  9860. .sp 1
  9861. .LP
  9862. .XS
  9863. Urange
  9864. .XE
  9865. The \fBset urange\fR and \fBset vrange\fR commands set the parametric ranges used
  9866. to compute x, y, and z values when in \fBsplot\fR parametric mode.  Please see
  9867. \fBset xrange\fR for details.
  9868. .sp 2
  9869. .NH 2
  9870. Variables
  9871. .sp 1
  9872. .LP
  9873. .XS
  9874. Variables
  9875. .XE
  9876. The \fBshow variables\fR command lists all user-defined variables and their
  9877. values.
  9878.  
  9879. Syntax:
  9880. .br
  9881.       show variables
  9882. .br
  9883. .sp 2
  9884. .NH 2
  9885. Version
  9886. .sp 1
  9887. .LP
  9888. .XS
  9889. Version
  9890. .XE
  9891. The \fBshow version\fR command lists the version of gnuplot being run, its last
  9892. modification date, the copyright holders, and email addresses for the FAQ,
  9893. the info-gnuplot mailing list, and reporting bugs--in short, the information
  9894. listed on the screen when the program is invoked interactively.
  9895.  
  9896. Syntax:
  9897. .br
  9898.       show version {long}
  9899. .br
  9900.  
  9901. When the \fBlong\fR option is given, it also lists the operating system, the
  9902. compilation options used when \fBgnuplot\fR was installed, the location of the
  9903. help file, and (again) the useful email addresses.
  9904. .sp 2
  9905. .NH 2
  9906. View
  9907. .sp 1
  9908. .LP
  9909. .XS
  9910. View
  9911. .XE
  9912. The \fBset view\fR command sets the viewing angle for \fBsplot\fRs.  It controls how
  9913. the 3-d coordinates of the plot are mapped into the 2-d screen space.  It
  9914. provides controls for both rotation and scaling of the plotted data, but
  9915. supports orthographic projections only.
  9916.  
  9917. Syntax:
  9918. .br
  9919.       set view <rot_x> {,{<rot_z>}{,{<scale>}{,<scale_z>}}}
  9920. .br
  9921. .br
  9922.       show view
  9923. .br
  9924.  
  9925. where <rot_x> and <rot_z> control the rotation angles (in degrees) in a
  9926. virtual 3-d coordinate system aligned with the screen such that initially
  9927. (that is, before the rotations are performed) the screen horizontal axis is
  9928. x, screen vertical axis is y, and the axis perpendicular to the screen is z.
  9929. The first rotation applied is <rot_x> around the x axis.  The second rotation
  9930. applied is <rot_z> around the new z axis.
  9931.  
  9932. <rot_x> is bounded to the [0:180] range with a default of 60 degrees, while
  9933. <rot_z> is bounded to the [0:360] range with a default of 30 degrees.
  9934. <scale> controls the scaling of the entire \fBsplot\fR, while <scale_z> scales
  9935. the z axis only.  Both scales default to 1.0.
  9936.  
  9937. Examples:
  9938. .br
  9939.       set view 60, 30, 1, 1
  9940. .br
  9941. .br
  9942.       set view ,,0.5
  9943. .br
  9944.  
  9945. The first sets all the four default values.  The second changes only scale,
  9946. to 0.5.
  9947.  
  9948. See also \fBset ticslevel\fR.
  9949. .sp 2
  9950. .NH 2
  9951. Vrange
  9952. .sp 1
  9953. .LP
  9954. .XS
  9955. Vrange
  9956. .XE
  9957. The \fBset urange\fR and \fBset vrange\fR commands set the parametric ranges used
  9958. to compute x, y, and z values when in \fBsplot\fR parametric mode.  Please see
  9959. \fBset xrange\fR for details.
  9960. .sp 2
  9961. .NH 2
  9962. X2data
  9963. .sp 1
  9964. .LP
  9965. .XS
  9966. X2data
  9967. .XE
  9968. The \fBset x2data\fR command sets data on the x2 (top) axis to timeseries
  9969. (dates/times).  Please see \fBset xdata\fR.
  9970. .sp 2
  9971. .NH 2
  9972. X2dtics
  9973. .sp 1
  9974. .LP
  9975. .XS
  9976. X2dtics
  9977. .XE
  9978. The \fBset x2dtics\fR command changes tics on the x2 (top) axis to days of the
  9979. week.  Please see \fBset xdtics\fR for details.
  9980. .sp 2
  9981. .NH 2
  9982. X2label
  9983. .sp 1
  9984. .LP
  9985. .XS
  9986. X2label
  9987. .XE
  9988. The \fBset x2label\fR command sets the label for the x2 (top) axis.  Please see
  9989. \fBset xlabel\fR.
  9990. .sp 2
  9991. .NH 2
  9992. X2mtics
  9993. .sp 1
  9994. .LP
  9995. .XS
  9996. X2mtics
  9997. .XE
  9998. The \fBset x2mtics\fR command changes tics on the x2 (top) axis to months of the
  9999. year.  Please see \fBset xmtics\fR for details.
  10000. .sp 2
  10001. .NH 2
  10002. X2range
  10003. .sp 1
  10004. .LP
  10005. .XS
  10006. X2range
  10007. .XE
  10008. The \fBset x2range\fR command sets the horizontal range that will be displayed on
  10009. the x2 (top) axis.  Please see \fBset xrange\fR for details.
  10010. .sp 2
  10011. .NH 2
  10012. X2tics
  10013. .sp 1
  10014. .LP
  10015. .XS
  10016. X2tics
  10017. .XE
  10018. The \fBset x2tics\fR command controls major (labelled) tics on the x2 (top) axis.
  10019. Please see \fBset xtics\fR for details.
  10020. .sp 2
  10021. .NH 2
  10022. X2zeroaxis
  10023. .sp 1
  10024. .LP
  10025. .XS
  10026. X2zeroaxis
  10027. .XE
  10028. The \fBset x2zeroaxis\fR command draws a line at the origin of the x2 (top) axis
  10029. (y2 = 0).  For details, please see
  10030. \fBset zeroaxis\fR.
  10031. .sp 2
  10032. .NH 2
  10033. Xdata
  10034. .sp 1
  10035. .LP
  10036. .XS
  10037. Xdata
  10038. .XE
  10039. This command sets the datatype on the x axis to time/date.  A similar command
  10040. does the same thing for each of the other axes.
  10041.  
  10042. Syntax:
  10043. .br
  10044.       set xdata {time}
  10045. .br
  10046. .br
  10047.       show xdata
  10048. .br
  10049.  
  10050. The same syntax applies to \fBydata\fR, \fBzdata\fR, \fBx2data\fR and \fBy2data\fR.
  10051.  
  10052. The \fBtime\fR option signals that the datatype is indeed time/date.  If the
  10053. option is not specified, the datatype reverts to normal.
  10054.  
  10055. See \fBset timefmt\fR to tell \fBgnuplot\fR how to read date or time data.  The
  10056. time/date is converted to seconds from start of the century.  There is
  10057. currently only one timefmt, which implies that all the time/date columns must
  10058. confirm to this format.  Specification of ranges should be supplied as quoted
  10059. strings according to this format to avoid interpretation of the time/date as
  10060. an expression.
  10061.  
  10062. The function \&'strftime\&' (type "man strftime" on unix to look it up) is used
  10063. to print tic-mark labels.  \fBgnuplot\fR tries to figure out a reasonable format
  10064. for this  unless the \fBset format x "string"\fR has supplied something that does
  10065. not look like a decimal format (more than one \&'%\&' or neither %f nor %g).
  10066.  
  10067. See also \fBTime/date\fR for more information.
  10068. .sp 2
  10069. .NH 2
  10070. Xdtics
  10071. .sp 1
  10072. .LP
  10073. .XS
  10074. Xdtics
  10075. .XE
  10076. The \fBset xdtics\fR commands converts the x-axis tic marks to days of the week
  10077. where 0=Sun and 6=Sat.  Overflows are converted modulo 7 to dates.  \fBset
  10078. noxdtics\fR returns the labels to their default values.  Similar commands do
  10079. the same things for the other axes.
  10080.  
  10081. Syntax:
  10082. .br
  10083.       set xdtics
  10084. .br
  10085. .br
  10086.       set noxdtics
  10087. .br
  10088. .br
  10089.       show xdtics
  10090. .br
  10091.  
  10092. The same syntax applies to \fBydtics\fR, \fBzdtics\fR, \fBx2dtics\fR and \fBy2dtics\fR.
  10093.  
  10094. See also the \fBset format\fR command.
  10095. .sp 2
  10096. .NH 2
  10097. Xlabel
  10098. .sp 1
  10099. .LP
  10100. .XS
  10101. Xlabel
  10102. .XE
  10103. The \fBset xlabel\fR command sets the x axis label.  Similar commands set labels
  10104. on the other axes.
  10105.  
  10106. Syntax:
  10107. .br
  10108.       set xlabel {"<label>"} {<xoff>}{,<yoff>} {"<font>{,<size>}"}
  10109. .br
  10110. .br
  10111.       show xlabel
  10112. .br
  10113.  
  10114. The same syntax applies to \fBx2label\fR, \fBylabel\fR, \fBy2label\fR and \fBzlabel\fR.
  10115.  
  10116. Specifying the constants <xoff> or <yoff> as optional offsets for a label
  10117. will move it <xoff> or <yoff> character widths or heights.  For example,
  10118. "\fB set xlabel -1\fR" will change only the x offset of the xlabel, moving the
  10119. label roughly one character width to the left.   The size of a character
  10120. depends on both the font and the terminal.
  10121.  
  10122. <font> is used to specify the font in which the label is written; the units
  10123. of the font <size> depend upon which terminal is used.
  10124.  
  10125. To clear a label, put no options on the command line, e.g., "\fBset y2label\fR".
  10126.  
  10127. The default positions of the axis labels are as follows:
  10128.  
  10129. xlabel:  The x-axis label is centered below the bottom axis.
  10130.  
  10131. ylabel:  The position of the y-axis label depends on the terminal, and can be
  10132. one of the following three positions:
  10133.  
  10134. 1. Horizontal text flushed left at the top left of the plot.  Terminals that
  10135. cannot rotate text will probably use this method.  If \fBset x2tics\fR is also
  10136. in use, the ylabel may overwrite the left-most x2tic label.  This may be
  10137. remedied by adjusting the ylabel position or the left margin.
  10138.  
  10139. 2. Vertical text centered vertically at the left of the plot.  Terminals
  10140. that can rotate text will probably use this method.
  10141.  
  10142. 3. Horizontal text centered vertically at the left of the plot.  The EEPIC,
  10143. LaTeX and TPIC drivers use this method.  The user must insert line breaks
  10144. using \\\\ to prevent the ylabel from overwriting the plot.  To produce a
  10145. vertical row of characters, add \\\\ between every printing character (but this
  10146. is ugly).
  10147.  
  10148. zlabel: The z-axis label is centered along the z axis and placed in the space
  10149. above the grid level.
  10150.  
  10151. y2label: The y2-axis label is placed to the right of the y2 axis.  The
  10152. position is terminal-dependent in the same manner as is the y-axis label.
  10153.  
  10154. x2label: The x2-axis label is placed above the top axis but below the plot
  10155. title.  It is also possible to create an x2-axis label by using new-line
  10156. characters to make a multi-line plot title, e.g.,
  10157.  
  10158. .br
  10159.       set title "This is the title\\n\\nThis is the x2label"
  10160. .br
  10161.  
  10162. Note that double quotes must be used.  The same font will be used for both
  10163. lines, of course.
  10164.  
  10165. If you are not satisfied with the default position of an axis label, use \fBset
  10166. label\fR instead--that command gives you much more control over where text is
  10167. placed.
  10168.  
  10169. Please see \fBset syntax\fR for further information about backslash processing
  10170. and the difference between single- and double-quoted strings.
  10171. .sp 2
  10172. .NH 2
  10173. Xmtics
  10174. .sp 1
  10175. .LP
  10176. .XS
  10177. Xmtics
  10178. .XE
  10179. The \fBset xmtics\fR commands converts the x-axis tic marks to months of the
  10180. year where 1=Jan and 12=Dec.  Overflows are converted modulo 12 to months.
  10181. The tics are returned to their default labels by \fBset noxmtics\fR.  Similar
  10182. commands perform the same duties for the other axes.
  10183.  
  10184. Syntax:
  10185. .br
  10186.       set xmtics
  10187. .br
  10188. .br
  10189.       set noxmtics
  10190. .br
  10191. .br
  10192.       show xmtics
  10193. .br
  10194.  
  10195. The same syntax applies to \fBx2mtics\fR, \fBymtics\fR, \fBy2mtics\fR, and \fBzmtics\fR.
  10196.  
  10197. See also the \fBset format\fR command.
  10198. .sp 2
  10199. .NH 2
  10200. Xrange
  10201. .sp 1
  10202. .LP
  10203. .XS
  10204. Xrange
  10205. .XE
  10206. The \fBset xrange\fR command sets the horizontal range that will be displayed.
  10207. A similar command exists for each of the other axes, as well as for the
  10208. polar radius r and the parametric variables t, u, and v.
  10209.  
  10210. Syntax:
  10211. .br
  10212.       set xrange [{{<min>}:{<max>}}] {{no}reverse} {{no}writeback}
  10213. .br
  10214. .br
  10215.       show xrange
  10216. .br
  10217.  
  10218. where <min> and <max> terms are constants, expressions or an asterisk to set
  10219. autoscaling.  If the data are time/date, you must give the range as a quoted
  10220. string according to the \fBset timefmt\fR format.  Any value omitted will not be
  10221. changed.
  10222.  
  10223. The same syntax applies to \fByrange\fR, \fBzrange\fR, \fBx2range\fR, \fBy2range\fR,
  10224. \fBrrange\fR, \fBtrange\fR, \fBurange\fR and \fBvrange\fR.
  10225.  
  10226. The \fBreverse\fR option reverses the direction of the axis, e.g., \fBset xrange
  10227. [0:1] reverse\fR will produce an axis with 1 on the left and 0 on the right.
  10228. This is identical to the axis produced by \fBset xrange [1:0]\fR, of course.
  10229. \fBreverse\fR is intended primarily for use with \fBautoscale\fR.
  10230.  
  10231. The \fBwriteback\fR option essentially saves the range found by \fBautoscale\fR in
  10232. the buffers that would be filled by \fBset xrange\fR.  This is useful if you wish
  10233. to plot several functions together but have the range determined by only
  10234. some of them.  The \fBwriteback\fR operation is performed during the \fBplot\fR
  10235. execution, so it must be specified before that command.  For example,
  10236.  
  10237. .br
  10238.       set xrange [-10:10]
  10239. .br
  10240. .br
  10241.       set yrange [] writeback
  10242. .br
  10243. .br
  10244.       plot sin(x)
  10245. .br
  10246. .br
  10247.       set noautoscale y
  10248. .br
  10249. .br
  10250.       replot x/2
  10251. .br
  10252.  
  10253. results in a yrange of [-1:1] as found only from the range of sin(x); the
  10254. [-5:5] range of x/2 is ignored.  Executing \fBshow yrange\fR after each command
  10255. in the above example should help you understand what is going on.
  10256.  
  10257. In 2-d, \fBxrange\fR and \fByrange\fR determine the extent of the axes, \fBtrange\fR
  10258. determines the range of the parametric variable in parametric mode or the
  10259. range of the angle in polar mode.  Similarly in parametric 3-d, \fBxrange\fR,
  10260. \fByrange\fR, and \fBzrange\fR govern the axes and \fBurange\fR and \fBvrange\fR govern the
  10261. parametric variables.
  10262.  
  10263. In polar mode, \fBrrange\fR determines the radial range plotted.  <rmin> acts as
  10264. an additive constant to the radius, whereas <rmax> acts as a clip to the
  10265. radius---no point with radius greater than <rmax> will be plotted.  \fBxrange\fR
  10266. and \fByrange\fR are affected---the ranges can be set as if the graph was of
  10267. r(t)-rmin, with rmin added to all the labels.
  10268.  
  10269. Any range may be partially or totally autoscaled, although it may not make
  10270. sense to autoscale a parametric variable unless it is plotted with data.
  10271.  
  10272. Ranges may also be specified on the \fBplot\fR command line.  A range given on
  10273. the plot line will be used for that single \fBplot\fR command; a range given by
  10274. a \fBset\fR command will be used for all subsequent plots that do not specify
  10275. their own ranges.  The same holds true for \fBsplot\fR.
  10276.  
  10277. Examples:
  10278.  
  10279. To set the xrange to the default:
  10280. .br
  10281.       set xrange [-10:10]
  10282. .br
  10283.  
  10284. To set the yrange to increase downwards:
  10285. .br
  10286.       set yrange [10:-10]
  10287. .br
  10288.  
  10289. To change zmax to 10 without affecting zmin (which may still be autoscaled):
  10290. .br
  10291.       set zrange [:10]
  10292. .br
  10293.  
  10294. To autoscale xmin while leaving xmax unchanged:
  10295. .br
  10296.       set xrange [*:]
  10297. .br
  10298. .sp 2
  10299. .NH 2
  10300. Xtics
  10301. .sp 1
  10302. .LP
  10303. .XS
  10304. Xtics
  10305. .XE
  10306. Fine control of the major (labelled) tics on the x axis is possible with the
  10307. \fBset xtics\fR command.  The tics may be turned off with the \fBset noxtics\fR
  10308. command, and may be turned on (the default state) with \fBset xtics\fR.  Similar
  10309. commands control the major tics on the y, z, x2 and y2 axes.
  10310.  
  10311. Syntax:
  10312. .br
  10313.       set xtics {axis | border} {{no}mirror} {{no}rotate}
  10314. .br
  10315. .br
  10316.                 {  autofreq
  10317. .br
  10318. .br
  10319.                  | <incr>
  10320. .br
  10321. .br
  10322.                  | <start>, <incr> {,<end>}
  10323. .br
  10324. .br
  10325.                  | ({"<label>"} <pos> {,{"<label>"} <pos>}...) }
  10326. .br
  10327. .br
  10328.       set noxtics
  10329. .br
  10330. .br
  10331.       show xtics
  10332. .br
  10333.  
  10334. The same syntax applies to \fBytics\fR, \fBztics\fR, \fBx2tics\fR and \fBy2tics\fR.
  10335.  
  10336. \fBaxis\fR or \fBborder\fR tells \fBgnuplot\fR to put the tics (both the tics themselves
  10337. and the accompanying labels) along the axis or the border, respectively.  If
  10338. the axis is very close to the border, the \fBaxis\fR option can result in tic
  10339. labels overwriting other text written in the margin.
  10340.  
  10341. \fBmirror\fR tells \fBgnuplot\fR to put unlabelled tics at the same positions on the
  10342. opposite border.  \fBnomirror\fR does what you think it does.
  10343.  
  10344. \fBrotate\fR asks \fBgnuplot\fR to rotate the text through 90 degrees, which will be
  10345. done if the terminal driver in use supports text rotation.  \fBnorotate\fR
  10346. cancels this.
  10347.  
  10348. The defaults are \fBborder mirror norotate\fR for tics on the x and y axes, and
  10349. \fBborder nomirror norotate\fR for tics on the x2 and y2 axes.  For the z axis,
  10350. the the \fB{axis | border}\fR option is not available and the default is
  10351. \fBnomirror\fR.  If you do want to mirror the z-axis tics, you might want to
  10352. create a bit more room for them with \fBset border\fR.
  10353.  
  10354. \fBset xtics\fR with no options restores the default border or axis if xtics are
  10355. being displayed;  otherwise it has no effect.  Any previously specified tic
  10356. frequency or position {and labels} are retained.
  10357.  
  10358. Positions of the tics are calculated automatically by default or if the
  10359. \fBautofreq\fR option is given; otherwise they may be specified in either of
  10360. two forms:
  10361.  
  10362. The implicit <start>, <incr>, <end> form specifies that a series of tics will
  10363. be plotted on the axis between the values <start> and <end> with an increment
  10364. of <incr>.  If <end> is not given, it is assumed to be infinity.  The
  10365. increment may be negative.  If neither <start> nor <end> is given, <start> is
  10366. assumed to be negative infinity, <end> is assumed to be positive infinity,
  10367. and the tics will be drawn at integral multiples of <step>.  If the axis is
  10368. logarithmic, the increment will be used as a multiplicative factor.
  10369.  
  10370. Examples:
  10371.  
  10372. Make tics at 0, 0.5, 1, 1.5, ..., 9.5, 10.
  10373. .br
  10374.       set xtics 0,.5,10
  10375. .br
  10376.  
  10377. Make tics at ..., -10, -5, 0, 5, 10, ...
  10378. .br
  10379.       set xtics 5
  10380. .br
  10381.  
  10382. Make tics at 1, 100, 1e4, 1e6, 1e8.
  10383. .br
  10384.       set logscale x; set xtics 1,100,10e8
  10385. .br
  10386.  
  10387. The explicit ("<label>" <pos>, ...) form allows arbitrary tic positions or
  10388. non-numeric tic labels.  A set of tics is a set of positions, each with its
  10389. own optional label.  Note that the label is a string enclosed by quotes.  It
  10390. may be a constant string, such as "hello", may contain formatting information
  10391. for converting the position into its label, such as "%3f clients", or may be
  10392. empty, "".  See \fBset format\fR for more information.  If no string is given,
  10393. the default label (numerical) is used.  In this form, the tics do not need to
  10394. be listed in numerical order.
  10395.  
  10396. Examples:
  10397. .br
  10398.       set xtics ("low" 0, "medium" 50, "high" 100)
  10399. .br
  10400. .br
  10401.       set xtics (1,2,4,8,16,32,64,128,256,512,1024)
  10402. .br
  10403. .br
  10404.       set ytics ("bottom" 0, "" 10, "top" 20)
  10405. .br
  10406.  
  10407. In the second example, all tics are labelled.  In the third, only the end
  10408. tics are labelled.
  10409.  
  10410. However they are specified, tics will only be plotted when in range.
  10411.  
  10412. Format (or omission) of the tic labels is controlled by \fBset format\fR, unless
  10413. the explicit text of a labels is included in the \fBset xtic (\fR<label>\fB)\fR form.
  10414.  
  10415. Minor (unlabelled) tics can be added by the \fBset mxtics\fR command.
  10416.  
  10417. In case of timeseries data, position values must be given as quoted dates
  10418. or times according to the format \fBtimefmt\fR.  If the <start>, <incr>, <end>
  10419. form is used, <start> and <end> must be given according to \fBtimefmt\fR, but
  10420. <incr> must be in seconds.  Times will be written out according to the format
  10421. given on \fBset format\fR, however.
  10422.  
  10423. Examples:
  10424. .br
  10425.       set xdata time
  10426. .br
  10427. .br
  10428.       set timefmt "%d/%m"
  10429. .br
  10430. .br
  10431.       set format x "%b %d"
  10432. .br
  10433. .br
  10434.       set xrange ["01/12":"06/12"]
  10435. .br
  10436. .br
  10437.       set xtics "01/12", 172800, "05/12"
  10438. .br
  10439.  
  10440. .br
  10441.       set xdata time
  10442. .br
  10443. .br
  10444.       set timefmt "%d/%m"
  10445. .br
  10446. .br
  10447.       set format x "%b %d"
  10448. .br
  10449. .br
  10450.       set xrange ["01/12":"06/12"]
  10451. .br
  10452. .br
  10453.       set xtics ("01/12", "" "03/12", "05/12")
  10454. .br
  10455. Both of these will produce tics "Dec 1", "Dec 3", and "Dec 5", but in the
  10456. second example the tic at "Dec 3" will be unlabelled.
  10457.  
  10458. .sp 2
  10459. .NH 2
  10460. Xzeroaxis
  10461. .sp 1
  10462. .LP
  10463. .XS
  10464. Xzeroaxis
  10465. .XE
  10466. The \fBset xzeroaxis\fR command draws a line at y = 0.  For details, please see
  10467. \fBset zeroaxis\fR.
  10468. .sp 2
  10469. .NH 2
  10470. Y2data
  10471. .sp 1
  10472. .LP
  10473. .XS
  10474. Y2data
  10475. .XE
  10476. The \fBset y2data\fR command sets y2 (right-hand) axis data to timeseries
  10477. (dates/times).  Please see \fBset xdata\fR.
  10478. .sp 2
  10479. .NH 2
  10480. Y2dtics
  10481. .sp 1
  10482. .LP
  10483. .XS
  10484. Y2dtics
  10485. .XE
  10486. The \fBset y2dtics\fR command changes tics on the y2 (right-hand) axis to days of
  10487. the week.  Please see \fBset xdtics\fR for details.
  10488. .sp 2
  10489. .NH 2
  10490. Y2label
  10491. .sp 1
  10492. .LP
  10493. .XS
  10494. Y2label
  10495. .XE
  10496. The \fBset y2dtics\fR command sets the label for the y2 (right-hand) axis.
  10497. Please see \fBset xlabel\fR.
  10498. .sp 2
  10499. .NH 2
  10500. Y2mtics
  10501. .sp 1
  10502. .LP
  10503. .XS
  10504. Y2mtics
  10505. .XE
  10506. The \fBset y2mtics\fR command changes tics on the y2 (right-hand) axis to months
  10507. of the year.  Please see \fBset xmtics\fR for details.
  10508. .sp 2
  10509. .NH 2
  10510. Y2range
  10511. .sp 1
  10512. .LP
  10513. .XS
  10514. Y2range
  10515. .XE
  10516. The \fBset y2range\fR command sets the vertical range that will be displayed on
  10517. the y2 (right-hand) axis.  Please see \fBset xrange\fR for details.
  10518. .sp 2
  10519. .NH 2
  10520. Y2tics
  10521. .sp 1
  10522. .LP
  10523. .XS
  10524. Y2tics
  10525. .XE
  10526. The \fBset y2tics\fR command controls major (labelled) tics on the y2 (right-hand)
  10527. axis.  Please see \fBset xtics\fR for details.
  10528. .sp 2
  10529. .NH 2
  10530. Y2zeroaxis
  10531. .sp 1
  10532. .LP
  10533. .XS
  10534. Y2zeroaxis
  10535. .XE
  10536. The \fBset y2zeroaxis\fR command draws a line at the origin of the y2 (right-hand)
  10537. axis (x2 = 0).  For details, please see \fBset zeroaxis\fR.
  10538. .sp 2
  10539. .NH 2
  10540. Ydata
  10541. .sp 1
  10542. .LP
  10543. .XS
  10544. Ydata
  10545. .XE
  10546. Sets y-axis data to timeseries (dates/times).  Please see \fBset xdata\fR.
  10547. .sp 2
  10548. .NH 2
  10549. Ydtics
  10550. .sp 1
  10551. .LP
  10552. .XS
  10553. Ydtics
  10554. .XE
  10555. The \fBset ydtics\fR command changes tics on the y axis to days of the week.
  10556. Please see \fBset xdtics\fR for details.
  10557. .sp 2
  10558. .NH 2
  10559. Ylabel
  10560. .sp 1
  10561. .LP
  10562. .XS
  10563. Ylabel
  10564. .XE
  10565. This command sets the label for the y axis.  Please see \fBset xlabel\fR.
  10566. .sp 2
  10567. .NH 2
  10568. Ymtics
  10569. .sp 1
  10570. .LP
  10571. .XS
  10572. Ymtics
  10573. .XE
  10574. The \fBset ymtics\fR command changes tics on the y axis to months of the year.
  10575. Please see \fBset xmtics\fR for details.
  10576. .sp 2
  10577. .NH 2
  10578. Yrange
  10579. .sp 1
  10580. .LP
  10581. .XS
  10582. Yrange
  10583. .XE
  10584. The \fBset yrange\fR command sets the vertical range that will be displayed on
  10585. the y axis.  Please see \fBset xrange\fR for details.
  10586. .sp 2
  10587. .NH 2
  10588. Ytics
  10589. .sp 1
  10590. .LP
  10591. .XS
  10592. Ytics
  10593. .XE
  10594. The \fBset ytics\fR command controls major (labelled) tics on the y axis.
  10595. Please see \fBset xtics\fR for details.
  10596. .sp 2
  10597. .NH 2
  10598. Yzeroaxis
  10599. .sp 1
  10600. .LP
  10601. .XS
  10602. Yzeroaxis
  10603. .XE
  10604. The \fBset yzeroaxis\fR command draws a line at x = 0.  For details, please see
  10605. \fBset zeroaxis\fR.
  10606. .sp 2
  10607. .NH 2
  10608. Zdata
  10609. .sp 1
  10610. .LP
  10611. .XS
  10612. Zdata
  10613. .XE
  10614. Set zaxis date to timeseries (dates/times).  Please see \fBset xdata\fR.
  10615. .sp 2
  10616. .NH 2
  10617. Zdtics
  10618. .sp 1
  10619. .LP
  10620. .XS
  10621. Zdtics
  10622. .XE
  10623. The \fBset zdtics\fR command changes tics on the z axis to days of the week.
  10624. Please see \fBset xdtics\fR for details.
  10625. .sp 2
  10626. .NH 2
  10627. Zero
  10628. .sp 1
  10629. .LP
  10630. .XS
  10631. Zero
  10632. .XE
  10633. The \fBzero\fR value is the default threshold for values approaching 0.0.
  10634.  
  10635. Syntax:
  10636. .br
  10637.       set zero <expression>
  10638. .br
  10639. .br
  10640.       show zero
  10641. .br
  10642.  
  10643. \fBgnuplot\fR will not plot a point if its imaginary part is greater in magnitude
  10644. than the \fBzero\fR threshold.  This threshold is also used in various other
  10645. parts of \fBgnuplot\fR as a (crude) numerical-error threshold.  The default
  10646. \fBzero\fR value is 1e-8.  \fBzero\fR values larger than 1e-3 (the reciprocal of the
  10647. number of pixels in a typical bitmap display) should probably be avoided, but
  10648. it is not unreasonable to set \fBzero\fR to 0.0.
  10649. .sp 2
  10650. .NH 2
  10651. Zeroaxis
  10652. .sp 1
  10653. .LP
  10654. .XS
  10655. Zeroaxis
  10656. .XE
  10657. The x axis may be drawn by \fBset xzeroaxis\fR and removed by \fBset noxzeroaxis\fR.
  10658. Similar commands behave similarly for the y, x2, and y2 axes.
  10659.  
  10660. Syntax:
  10661. .br
  10662.       set {x|x2|y|y2|}zeroaxis { {linestyle | ls <line_style>}
  10663. .br
  10664. .br
  10665.                                  | { linetype | lt <line_type>}
  10666. .br
  10667. .br
  10668.                                    { linewidth | lw <line_width>}}
  10669. .br
  10670. .br
  10671.       set no{x|x2|y|y2|}zeroaxis
  10672. .br
  10673. .br
  10674.       show {x|y|}zeroaxis
  10675. .br
  10676.  
  10677.  
  10678. By default, these options are off.  The selected zero axis is drawn
  10679. with a line of type <line_type> and width <line_width> (if supported
  10680. by the terminal driver currently in use), or a user-defined style
  10681. <line_style>.
  10682.  
  10683. If no linetype is specified, any zero axes selected will be drawn
  10684. using the axis linetype (linetype 0).
  10685.  
  10686. \fBset zeroaxis l\fR is equivalent to \fBset xzeroaxis l; set yzeroaxis l\fR. \fBset
  10687. nozeroaxis\fR is equivalent to \fBset noxzeroaxis; set noyzeroaxis\fR.
  10688. .sp 2
  10689. .NH 2
  10690. Zlabel
  10691. .sp 1
  10692. .LP
  10693. .XS
  10694. Zlabel
  10695. .XE
  10696. This command sets the label for the z axis.  Please see \fBset xlabel\fR.
  10697. .sp 2
  10698. .NH 2
  10699. Zmtics
  10700. .sp 1
  10701. .LP
  10702. .XS
  10703. Zmtics
  10704. .XE
  10705. The \fBset zmtics\fR command changes tics on the z axis to months of the year.
  10706. Please see \fBset xmtics\fR for details.
  10707. .sp 2
  10708. .NH 2
  10709. Zrange
  10710. .sp 1
  10711. .LP
  10712. .XS
  10713. Zrange
  10714. .XE
  10715. The \fBset zrange\fR command sets the range that will be displayed on the z axis.
  10716. The zrange is used only by \fBsplot\fR and is ignored by \fBplot\fR.  Please see \fBset
  10717. xrange\fR for details.
  10718. .sp 2
  10719. .NH 2
  10720. Ztics
  10721. .sp 1
  10722. .LP
  10723. .XS
  10724. Ztics
  10725. .XE
  10726. The \fBset ztics\fR command controls major (labelled) tics on the z axis.
  10727. Please see \fBset xtics\fR for details.
  10728. .sp 2
  10729. .RE
  10730. .br
  10731. .NH 1
  10732. Shell
  10733. .sp 1
  10734. .LP
  10735. .XS
  10736. Shell
  10737. .XE
  10738. The \fBshell\fR command spawns an interactive shell.  To return to \fBgnuplot\fR,
  10739. type \fBlogout\fR if using VMS, \fBexit\fR or the END-OF-FILE character if using
  10740. Unix, \fBendcli\fR if using AmigaOS, or \fBexit\fR if using MS-DOS or OS/2.
  10741.  
  10742. A single shell command may be spawned by preceding it with the ! character
  10743. ($ if using VMS) at the beginning of a command line.  Control will return
  10744. immediately to \fBgnuplot\fR after this command is executed.  For example, in
  10745. Unix, AmigaOS, MS-DOS or OS/2,
  10746.  
  10747. .br
  10748.       ! dir
  10749. .br
  10750.  
  10751. prints a directory listing and then returns to \fBgnuplot\fR.
  10752.  
  10753. On an Atari, the \fB!\fR command first checks whether a shell is already loaded
  10754. and uses it, if available.  This is practical if \fBgnuplot\fR is run from
  10755. \fBgulam\fR, for example.
  10756. .sp 2
  10757. .NH 1
  10758. Splot
  10759. .sp 1
  10760. .LP
  10761. .XS
  10762. Splot
  10763. .XE
  10764. \fBsplot\fR is the command for drawing 3-d plots (well, actually projections on
  10765. a 2-d surface, but you knew that).  It can create a plot from functions or
  10766. a data file in a manner very similar to the \fBplot\fR command.
  10767.  
  10768. See \fBplot\fR for features common to the \fBplot\fR command; only differences are
  10769. discussed in detail here.  Note specifically that the \fBbinary\fR and \fBmatrix\fR
  10770. options (discussed under "datafile-modifiers") are not available for \fBplot\fR.
  10771.  
  10772. Syntax:
  10773. .br
  10774.       splot {<ranges>}
  10775. .br
  10776. .br
  10777.             <function> | "<datafile>" {datafile-modifiers}}
  10778. .br
  10779. .br
  10780.             {<title-spec>} {with <style>}
  10781. .br
  10782. .br
  10783.             {, {definitions,} <function> ...}
  10784. .br
  10785.  
  10786. where either a <function> or the name of a data file enclosed in quotes is
  10787. supplied.  The function can be a mathematical expression, or a triple of
  10788. mathematical expressions in parametric mode.
  10789.  
  10790. By default \fBsplot\fR draws the xy plane completely below the plotted data.
  10791. The offset between the lowest ztic and the xy plane can be changed by \fBset
  10792. ticslevel\fR.  The orientation of a \fBsplot\fR projection is controlled by
  10793. \fBset view\fR.  See \fBset view\fR and \fBset ticslevel\fR for more information.
  10794.  
  10795. The syntax for setting ranges on the \fBsplot\fR command is the same as for
  10796. \fBplot\fR.  In non-parametric mode, the order in which ranges must be given is
  10797. \fBxrange\fR, \fByrange\fR, and \fBzrange\fR.  In parametric mode, the order is \fBurange\fR,
  10798. \fBvrange\fR, \fBxrange\fR, \fByrange\fR, and \fBzrange\fR.
  10799.  
  10800. The \fBtitle\fR option is the same as in \fBplot\fR.  The operation of \fBwith\fR is also
  10801. the same as in \fBplot\fR, except that the plotting styles available to \fBsplot\fR
  10802. are limited to \fBlines\fR, \fBpoints\fR, \fBlinespoints\fR, \fBdots\fR, and \fBimpulses\fR;  the
  10803. error-bar capabilities of \fBplot\fR are not available for \fBsplot\fR.
  10804.  
  10805. The datafile options have more differences.
  10806. .sp 2
  10807. .RS
  10808. .IP
  10809. .NH 2
  10810. Data-file
  10811. .sp 1
  10812. .LP
  10813. .XS
  10814. Data-file
  10815. .XE
  10816. As for \fBplot\fR, discrete data contained in a file can be displayed by
  10817. specifying the name of the data file, enclosed in quotes,  on the \fBsplot\fR
  10818. command line.
  10819.  
  10820. Syntax:
  10821. .br
  10822.       splot '<file_name>' {binary | matrix}
  10823. .br
  10824. .br
  10825.                           {index <index list>}
  10826. .br
  10827. .br
  10828.                           {every <every list>}
  10829. .br
  10830. .br
  10831.                           {using <using list>}
  10832. .br
  10833.  
  10834. The special filenames \fB""\fR and \fB"-"\fR are permitted, as in \fBplot\fR.
  10835.  
  10836. In brief, \fBbinary\fR and \fBmatrix\fR indicate that the the data are in a special
  10837. form, \fBindex\fR selects which data sets in a multi-data-set file are to be
  10838. plotted, \fBevery\fR specifies which datalines (subsets) within a single data
  10839. set are to be plotted, and \fBusing\fR determines how the columns within a single
  10840. record are to be interpreted.
  10841.  
  10842. The options \fBindex\fR and \fBevery\fR behave the same way as with \fBplot\fR;  \fBusing\fR
  10843. does so also, except that the \fBusing\fR list must provide three entries
  10844. instead of two.
  10845.  
  10846. The \fBplot\fR options \fBthru\fR and \fBsmooth\fR are not available for \fBsplot\fR, but
  10847. \fBcntrparams\fR and \fBdgrid3d\fR provide limited smoothing cabilities.
  10848.  
  10849. Data file organization is essentially the same as for \fBplot\fR, except that
  10850. each point is an (x,y,z) triple.  If only a single value is provided, it
  10851. will be used for z, the datablock number will be used for y, and the index
  10852. of the data point in the datablock will be used for x.  If two values are
  10853. provided, \fBgnuplot\fR gives you an error message.  Three values are interpreted
  10854. as an (x,y,z) triple.  Additional values are generally used as errors, which
  10855. can be used by \fBfit\fR.
  10856.  
  10857. Single blank records separate datablocks in a \fBsplot\fR datafile; \fBsplot\fR
  10858. treats datablocks as the equivalent of function y-isolines.  No line will
  10859. join points separated by a blank record.  If all datablocks contain the same
  10860. number of points, \fBgnuplot\fR will draw cross-isolines between datablocks,
  10861. connecting corresponding points.  This is termed "grid data", and is required
  10862. for drawing a surface, for contouring (\fBset contour\fR) and hidden-line removal
  10863. (\fBset hidden3d\fR). See also \fBsplot grid data\fR
  10864.  
  10865. It is no longer necessary to specify \fBparametric\fR mode for three-column
  10866. \fBsplot\fRs.
  10867. .sp 2
  10868. .RS
  10869. .IP
  10870. .NH 3
  10871. Binary
  10872. .sp 1
  10873. .LP
  10874. .XS
  10875. Binary
  10876. .XE
  10877. \fBsplot\fR can read binary files written with a specific format (and on a
  10878. system with a compatible binary file representation.)
  10879.  
  10880. In previous versions, \fBgnuplot\fR dynamically detected binary data files.  It
  10881. is now necessary to specify the keyword \fBbinary\fR directly after the filename.
  10882.  
  10883. Single precision floats are stored in a binary file as follows:
  10884.  
  10885. .br
  10886.       <N+1>  <y0>   <y1>   <y2>  ...  <yN>
  10887. .br
  10888. .br
  10889.        <x0> <z0,0> <z0,1> <z0,2> ... <z0,N>
  10890. .br
  10891. .br
  10892.        <x1> <z1,0> <z1,1> <z1,2> ... <z1,N>
  10893. .br
  10894. .br
  10895.         :      :      :      :   ...    :
  10896. .br
  10897.  
  10898. which are converted into triplets:
  10899. .br
  10900.       <x0> <y0> <z0,0>
  10901. .br
  10902. .br
  10903.       <x0> <y1> <z0,1>
  10904. .br
  10905. .br
  10906.       <x0> <y2> <z0,2>
  10907. .br
  10908. .br
  10909.        :    :     :
  10910. .br
  10911. .br
  10912.       <x0> <yN> <z0,N>
  10913. .br
  10914.  
  10915. .br
  10916.       <x1> <y0> <z1,0>
  10917. .br
  10918. .br
  10919.       <x1> <y1> <z1,1>
  10920. .br
  10921. .br
  10922.        :    :     :
  10923. .br
  10924.  
  10925. These triplets are then converted into \fBgnuplot\fR iso-curves and then
  10926. \fBgnuplot\fR proceeds in the usual manner to do the rest of the plotting.
  10927.  
  10928. A collection of matrix and vector manipulation routines (in C) is provided
  10929. in \fBbinary.c\fR.  The routine to write binary data is
  10930.  
  10931. .br
  10932.       int fwrite_matrix(file,m,nrl,nrl,ncl,nch,row_title,column_title)
  10933. .br
  10934.  
  10935. An example of using these routines is provided in the file \fBbf_test.c\fR, which
  10936. generates binary files for the demo file \fBdemo/binary.dem\fR.
  10937.  
  10938. The \fBindex\fR keyword is not supported, since the file format allows only one
  10939. surface per file.  The \fBevery\fR and \fBusing\fR filters are supported.  \fBusing\fR
  10940. operates as if the data were read in the above triplet form.
  10941. .sp 2
  10942. .NH 3
  10943. Example datafile
  10944. .sp 1
  10945. .LP
  10946. .XS
  10947. Example datafile
  10948. .XE
  10949. A simple example of plotting a 3-d data file is
  10950.  
  10951. .br
  10952.       splot 'datafile.dat'
  10953. .br
  10954.  
  10955. where the file "datafile.dat" might contain:
  10956.  
  10957. .br
  10958.       # The valley of the Gnu.
  10959. .br
  10960. .br
  10961.          0 0 10
  10962. .br
  10963. .br
  10964.          0 1 10
  10965. .br
  10966. .br
  10967.          0 2 10
  10968. .br
  10969.  
  10970. .br
  10971.          1 0 10
  10972. .br
  10973. .br
  10974.          1 1 5
  10975. .br
  10976. .br
  10977.          1 2 10
  10978. .br
  10979.  
  10980. .br
  10981.          2 0 10
  10982. .br
  10983. .br
  10984.          2 1 1
  10985. .br
  10986. .br
  10987.          2 2 10
  10988. .br
  10989.  
  10990. .br
  10991.          3 0 10
  10992. .br
  10993. .br
  10994.          3 1 0
  10995. .br
  10996. .br
  10997.          3 2 10
  10998. .br
  10999.  
  11000. Note that "datafile.dat" defines a 4 by 3 grid ( 4 rows of 3 points each ).
  11001. Rows (datablocks) are separated by blank records.
  11002.  
  11003. Note also that the x value is held constant within each dataline.  If you
  11004. instead keep y constant, and plot with hidden-line removal enabled, you will
  11005. find that the surface is drawn \&'inside-out\&'.
  11006.  
  11007. Actually for grid data it is not necessary to keep the x values constant
  11008. within a datablock, nor is it necessary to keep the same sequence of y
  11009. values.  \fBgnuplot\fR requires only that the number of points be the same for
  11010. each datablock.  However since the surface mesh, from which contours are
  11011. derived, connects sequentially corresponding points, the effect of an
  11012. irregular grid on a surface plot is unpredictable and should be examined
  11013. on a case-by-case basis.
  11014. .sp 2
  11015. .NH 3
  11016. Matrix
  11017. .sp 1
  11018. .LP
  11019. .XS
  11020. Matrix
  11021. .XE
  11022. The \fBmatrix\fR flag indicates that the ASCII data are stored in matrix format.
  11023. The z-values are read in a row at a time, i. e.,
  11024. .br
  11025.       z11 z12 z13 z14 ...
  11026. .br
  11027. .br
  11028.       z21 z22 z23 z24 ...
  11029. .br
  11030. .br
  11031.       z31 z32 z33 z34 ...
  11032. .br
  11033. and so forth.  The row and column indices are used for the x- and y-values.
  11034. .sp 2
  11035. .RE
  11036. .br
  11037. .NH 2
  11038. Grid_data
  11039. .sp 1
  11040. .LP
  11041. .XS
  11042. Grid_data
  11043. .XE
  11044. The 3D routines are designed for points in a grid format, with one sample,
  11045. datapoint, at each mesh intersection; the datapoints may originate from
  11046. either evaluating a function, see \fBset isosamples\fR, or reading a datafile,
  11047. see \fBsplot datafile\fR.  The term "isoline" is applied to the mesh lines for
  11048. both functions and data.  Note that the mesh need not be rectangular in x
  11049. and y, as it may be parameterized in u and v, see \fBset isosamples\fR.
  11050.  
  11051. However, \fBgnuplot\fR does not require that format.  In the case of functions,
  11052. \&\&'samples\&' need not be equal to \&'isosamples\&', i.e., not every x-isoline
  11053. sample need intersect a y-isoline. In the case of data files, if there
  11054. are an equal number of scattered data points in each datablock, then
  11055. "isolines" will connect the points in a datablock, and "cross-isolines"
  11056. will connect the corresponding points in each datablock to generate a
  11057. "surface".  In either case, contour and hidden3d modes may give different
  11058. plots than if the points were in the intended format.  Scattered data can be
  11059. converted to a {different} grid format with \fBset dgrid3d\fR.
  11060.  
  11061. The contour code tests for z intensity along a line between a point on a
  11062. y-isoline and the corresponding point in the next y-isoline.  Thus a \fBsplot\fR
  11063. contour of a surface with samples on the x-isolines that do not coincide with
  11064. a y-isoline intersection will ignore such samples. Try:
  11065. .br
  11066.        set xrange [-pi/2:pi/2]; set yrange [-pi/2:pi/2]
  11067. .br
  11068. .br
  11069.        set function style lp
  11070. .br
  11071. .br
  11072.        set contour
  11073. .br
  11074. .br
  11075.        set isosamples 10,10; set samples 10,10;
  11076. .br
  11077. .br
  11078.        splot cos(x)*cos(y)
  11079. .br
  11080. .br
  11081.        set samples 4,10; replot
  11082. .br
  11083. .br
  11084.        set samples 10,4; replot
  11085. .br
  11086.  
  11087. .sp 2
  11088. .NH 2
  11089. Splot_overview
  11090. .sp 1
  11091. .LP
  11092. .XS
  11093. Splot_overview
  11094. .XE
  11095. \fBsplot\fR can display a surface as a collection of points, or by connecting
  11096. those points.  As with \fBplot\fR, the points may be read from a data file or
  11097. result from evaluation of a function at specified intervals, see \fBset
  11098. isosamples\fR.  The surface may be approximated by connecting the points
  11099. with straight line segments, see \fBset surface\fR, in which case the surface
  11100. can be made opaque with \fBset hidden3d.\fR  The orientation from which the 3d
  11101. surface is viewed can be changed with \fBset view\fR.
  11102.  
  11103. Additionally, for points in a grid format, \fBsplot\fR can interpolate points
  11104. having a common amplitude (see \fBset contour\fR) and can then connect those
  11105. new points to display contour lines, either directly with straight-line
  11106. segments or smoothed lines (see \fBset cntrparams\fR).  Functions are already
  11107. evaluated in a grid format, determined by \fBset isosamples\fR and \fBset samples\fR,
  11108. while file data must either be in a grid format, as described in \fBdata-file\fR,
  11109. or be used to generate a grid (see \fBset dgrid3d\fR).
  11110.  
  11111. Contour lines may be displayed either on the surface or projected onto the
  11112. base.  The base projections of the contour lines may be written to a
  11113. file, and then read with \fBplot\fR, to take advantage of \fBplot\fR\&'s additional
  11114. formatting capabilities.
  11115. .sp 2
  11116. .RE
  11117. .br
  11118. .NH 1
  11119. Test
  11120. .sp 1
  11121. .LP
  11122. .XS
  11123. Test
  11124. .XE
  11125. \fBtest\fR creates a display of line and point styles and other useful things
  11126. appropriate for the terminal you are using.
  11127.  
  11128. Syntax:
  11129. .br
  11130.       test
  11131. .br
  11132. .sp 2
  11133. .NH 1
  11134. Update
  11135. .sp 1
  11136. .LP
  11137. .XS
  11138. Update
  11139. .XE
  11140. This command writes the current values of the fit parameters into the given
  11141. file, formatted as an initial-value file (as described in the \fBfit\fRsection).
  11142. This is useful for saving the current values for later use or for restarting
  11143. a converged or stopped fit.
  11144.  
  11145. Syntax:
  11146. .br
  11147.       update <filename> {<filename>}
  11148. .br
  11149.  
  11150. If a second filename is supplied, the updated values are written to this
  11151. file, and the original parameter file is left unmodified.
  11152.  
  11153. Otherwise, if the file already exists, \fBgnuplot\fR first renames it by
  11154. appending \fB.old\fR and then opens a new file.  That is, "\fBupdate \&'fred\&'\fR"
  11155. behaves the same as "\fB!rename fred fred.old; update \&'fred.old\&' \&'fred\&'\fR".
  11156. [On DOS and other systems that use the twelve-character "filename.ext"
  11157. naming convention, "ext" will be "\fBold\fR" and "filename" will be related
  11158. (hopefully recognizably) to the initial name.  Renaming is not done at all
  11159. on VMS systems, since they use file-versioning.]
  11160.  
  11161. Please see \fBfit\fR for more information.
  11162. .sp 3
  11163. .NH 1
  11164. Graphical User Interfaces
  11165. .sp 1
  11166. .LP
  11167. .XS
  11168. Graphical User Interfaces
  11169. .XE
  11170. Several graphical user interfaces have been written for \fBgnuplot\fR and one for
  11171. win32 is included in this distribution.  In addition, there is a Macintosh
  11172. interface at
  11173. .br
  11174.        ftp://ftp.ee.gatech.edu/pub/mac/gnuplot
  11175. .br
  11176. and several X11 interfaces include three Tcl/Tk located at the usual Tcl/Tk
  11177. repositories.
  11178. .sp 3
  11179. .NH 1
  11180. Bugs
  11181. .sp 1
  11182. .LP
  11183. .XS
  11184. Bugs
  11185. .XE
  11186. Floating point exceptions (floating point number too large/small, divide by
  11187. zero, etc.) may occasionally be generated by user defined functions.  Some of
  11188. the demos in particular may cause numbers to exceed the floating point range.
  11189. Whether the system ignores such exceptions (in which case \fBgnuplot\fR labels
  11190. the corresponding point as undefined) or aborts \fBgnuplot\fR depends on the
  11191. compiler/runtime environment.
  11192.  
  11193. The bessel functions do not work for complex arguments.
  11194.  
  11195. The gamma function does not work for complex arguments.
  11196.  
  11197. As of \fBgnuplot\fR version 3.7, all development has been done using ANSI C.
  11198. With current operating system, compiler, and library releases, the OS
  11199. specific bugs documented in release 3.5, now relegated to \fBold_bugs\fR, may
  11200. no longer be relevant.
  11201.  
  11202. Bugs reported since the current release may be located via the official
  11203. distribution site:
  11204. .br
  11205.        ftp://ftp.dartmouth.edu/pub/gnuplot
  11206. .br
  11207. .br
  11208.       http://www.cs.dartmouth.edu/gnuplot_info.html
  11209. .br
  11210.  
  11211. Please e-mail any bugs to bug-gnuplot@dartmouth.edu.
  11212. .sp 2
  11213. .NH 1
  11214. Old_bugs
  11215. .sp 1
  11216. .LP
  11217. .XS
  11218. Old_bugs
  11219. .XE
  11220. There is a bug in the stdio library for old Sun operating systems (SunOS
  11221. Sys4-3.2).  The "%g" format for \&'printf\&' sometimes incorrectly prints numbers
  11222. (e.g., 200000.0 as "2").  Thus, tic mark labels may be incorrect on a Sun4
  11223. version of \fBgnuplot\fR.  A work-around is to rescale the data or use the \fBset
  11224. format\fR command to change the tic mark format to "%7.0f" or some other
  11225. appropriate format.  This appears to have been fixed in SunOS 4.0.
  11226.  
  11227. Another bug: On a Sun3 under SunOS 4.0, and on Sun4\&'s under Sys4-3.2 and
  11228. SunOS 4.0, the \&'sscanf\&' routine incorrectly parses "00 12" with the format
  11229. "%f %f" and reads 0 and 0 instead of 0 and 12.  This affects data input.  If
  11230. the data file contains x coordinates that are zero but are specified like
  11231. \&\&'00\&', \&'000\&', etc, then you will read the wrong y values.  Check any data
  11232. files or upgrade the SunOS.  It appears to have been fixed in SunOS 4.1.1.
  11233.  
  11234. Suns appear to overflow when calculating exp(-x) for large x, so \fBgnuplot\fR
  11235. gets an undefined result.  One work-around is to make a user-defined function
  11236. like e(x) = x<-500 ? 0 : exp(x).  This affects plots of Gaussians (exp(-x*x))
  11237. in particular, since x*x grows quite rapidly.
  11238.  
  11239. Microsoft C 5.1 has a nasty bug associated with the %g format for \&'printf\&'.
  11240. When any of the formats "%.2g", "%.1g", "%.0g", "%.g" are used, \&'printf\&' will
  11241. incorrectly print numbers in the range 1e-4 to 1e-1.  Numbers that should be
  11242. printed in the %e format are incorrectly printed in the %f format, with the
  11243. wrong number of zeros after the decimal point.  To work around this problem,
  11244. use the %e or %f formats explicitly.
  11245.  
  11246. \fBgnuplot\fR, when compiled with Microsoft C, did not work correctly on two VGA
  11247. displays that were tested.  The CGA, EGA and VGA drivers should probably be
  11248. rewritten to use the Microsoft C graphics library.  \fBgnuplot\fR compiled with
  11249. Borland C++ uses the Turbo C graphics drivers and does work correctly with
  11250. VGA displays.
  11251.  
  11252. VAX/VMS 4.7 C compiler release 2.4 also has a poorly implemented %g format
  11253. for \&'printf\&'.  The numbers are printed numerically correct, but may not be in
  11254. the requested format.  The K&R second edition says that for the %g format, %e
  11255. is used if the exponent is less than -4 or greater than or equal to the
  11256. precision.  The VAX uses %e format if the exponent is less than -1.  The VAX
  11257. appears to take no notice of the precision when deciding whether to use %e or
  11258. %f for numbers less than 1.  To work around this problem, use the %e or %f
  11259. formats explicitly.  From the VAX C 2.4 release notes: e,E,f,F,g,G  Result
  11260. will always contain a decimal  point.  For g and G, trailing zeros will not
  11261. be removed from the result.
  11262.  
  11263. VAX/VMS 5.2 C compiler release 3.0 has a slightly better implemented %g
  11264. format than release 2.4, but not much.  Trailing decimal points are now
  11265. removed, but trailing zeros are still not removed from %g numbers in
  11266. exponential format.
  11267.  
  11268. The two preceding problems are actually in the libraries rather than in the
  11269. compilers.  Thus the problems will occur whether \fBgnuplot\fR is built using
  11270. either the DEC compiler or some other one (e.g. the latest gcc).
  11271.  
  11272. ULTRIX X11R3 has a bug that causes the X11 driver to display "every other"
  11273. graph.  The bug seems to be fixed in DEC\&'s release of X11R4 so newer releases
  11274. of ULTRIX don\&'t seem to have the problem.  Solutions for older sites include
  11275. upgrading the X11 libraries (from DEC or direct from MIT) or defining
  11276. ULTRIX_KLUDGE when compiling the x11.trm file.  Note that the kludge is not
  11277. an ideal fix, however.
  11278.  
  11279. The constant HUGE was incorrectly defined in the NeXT OS 2.0 operating
  11280. system.  HUGE should be set to 1e38 in plot.h. This error has been corrected
  11281. in the 2.1 version of NeXT OS.
  11282.  
  11283. Some older models of HP plotters do not have a page eject command \&'PG\&'.  The
  11284. current HPGL driver uses this command in HPGL_reset.  This may need to be
  11285. removed for these plotters.  The current PCL5 driver uses HPGL/2 for text as
  11286. well as graphics.  This should be modified to use scalable PCL fonts.
  11287.  
  11288. On the Atari version, it is not possible to send output directly to the
  11289. printer (using \fB/dev/lp\fR as output file), since CRs are added to LFs in
  11290. binary output.  As a work-around, write the output to a file and copy it to
  11291. the printer afterwards using a shell command.
  11292.  
  11293. On AIX 4, the literal \&'NaNq\&' in a datafile causes the special internal value
  11294. \&\&'not-a-number\&' to be stored, rather than setting an internal \&'undefined\&'
  11295. flag.  A workaround is to use \fBset missing \&'NaNq\&'\fR.
  11296.  
  11297. There may be an up-to-date list of bugs since the release on the WWW page:
  11298. .br
  11299.       http://www.cs.dartmouth.edu/gnuplot_info.html
  11300. .br
  11301.  
  11302. Please report any bugs to bug-gnuplot@dartmouth.edu.
  11303. .pn 1
  11304. .ds RH %
  11305. .af % i
  11306. .bp
  11307. .PX
  11308.